function y = mymean(x)
%MYMEAN Average or mean value.
% For vectors, MYMEAN(x) returns the 
% mean value.  For matrices, MYMEAN(x) 
% is a row vector containing the mean 
% value of each column.
[m,n] = size(x);
if m == 1
    m = n;
end
y = sum(x)/m;
