Mercurial > hg > ishara
view general/cellutils/cellmap.m @ 6:0ce3c2070089
Removed duplicate code and fixed doc in timed_action.
author | samer |
---|---|
date | Mon, 14 Jan 2013 14:33:37 +0000 |
parents | e44f49929e56 |
children | 47cb292350f3 |
line wrap: on
line source
function Y=cellmap(fn,X) % cellmap - Map a function over a cell array % % cellmap :: (A->B, {[Size]->A}) -> {[Size]->B} % preallocate to fix size Y=cell(size(X)); for i=1:numel(X) Y{i}=feval(fn,X{i}); end