This isn't a median filter. It's an average filter, and it's working on some arbitrary vectorized section of the image. Applying a 2D filter to a vector isn't going to accomplish anything of use here.
If you want to do median filtering, try doing median filtering.
noisypict = imread('noise1.png');
medfiltpict = zeros(size(noisypict),class(noisypict));
for c = 1:size(noisypict,3)
medfiltpict(:,:,c) = medfilt2(noisypict(:,:,c),[fs fs]);