samer@4: function Y=prod1(X) samer@4: % prod1 - prod over dimension 1 and shiftdim 1 samer@4: % samer@4: % prod1 :: [[N M]] -> [[M]]. samer@4: samer@4: Z=prod(X,1); samer@4: S=size(Z); samer@4: Y=reshape(Z,[S(2:end) 1]);