Operations involving NaN as one of the operands is one common way to get a NaN in the output, but it is not the only way. See Wikipedia for a list of other operations that can generate a NaN. If all your data is finite, likely you computed 0/0.
x = 0/0
There are more ways to generate a NaN if infinity gets involved (such as if your calculations overflow.)
[0*Inf, Inf-Inf, Inf/Inf, rem(Inf, 0)]