Mercurial > hg > ishara
view general/arrutils/mapels.m @ 44:3cedfd4549ef
Code added since initial check in.
author | samer |
---|---|
date | Tue, 13 Jan 2015 14:03:17 +0000 |
parents | |
children |
line wrap: on
line source
function Z=mapels(f,X) % mapels - Map a function of a scalar over one or more arrays % % mapels :: % (A->B), % [Size->A] % -> [Size->B]. z1=f(X(1)); Z=repmat(z1,size(X)); for i=2:numel(X) Z(i)=f(X(i)); end