Re: Is NaN?



Shapper:
<SNIP us's function is NOT working...

> this is not working. I get the message "??? Function name must be a
string...

you're absolutely right - i was too quick in showing
<cellfun>'s added functionality (great stuff, TMW!)

c={'aa',pi,[nan;pi;nan],1:5,nan};
% now, there are two possibilities
% a) a LOCAL solution
r=cellfun(@(x) x(:)~=x(:),c,'uniformoutput',false);
r{:}
% b) a GLOBAL solution
r=cellfun(@(x) any(x(:)~=x(:)),c)

sorry for confusion!
us
.