MATLAB Answers

mutah
0

help In NAN problem

Asked by mutah
on 19 Nov 2013
Latest activity Answered by Sean de Wolski
on 19 Nov 2013
Hi
MY code generate 1000000 samples
and when i want to sum this samples
it give me NAN
what the problem ??

  0 Comments

Sign in to comment.

1 Answer

Sean de Wolski
Answer by Sean de Wolski
on 19 Nov 2013

Anything + NaN yields NaN. Use nansum() to sum ignoring nans.
doc nansum

  0 Comments

Sign in to comment.