for loop into new array?

Thread Starter

Judas543

Joined Jan 26, 2010
60
for r=1:length(raw)
extractedRow=raw(r, : )

if (sum(isnan(raw{r,1})))==1||(sum(isnan(raw{r,2})))==1||(sum(isnan(raw{r,3})))==1||(sum(isnan(raw{r,4})))==1
if errorReview{1}==0;
errorReview=extractedRow;

else
errorReview=vertcat(errorReview,extractedRow);


end
end
end

Basically it takes out all of the nans and puts them into errorReview, however I'm wondering how to copy the valid entries without the nans into a new array.
 
Last edited:
Top