Hello, say for example I would like to iterate each row, and ignore any NaN values in a matrix.
For example a 3x5 matrix (A):
[1 2 3 4 5 ]
[1 2 3 NaN,NaN]
I want the length of each row without NaN for iteration.
Hence the result will be:
for i = 1:size(A,1)
nonan = length(A(i,isnan(A)==0))
How can I code this? Thanks in advance.