Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

I have (double type) matrix where I have NaN values. I want to change all NaN values to 0 value. How Can I do that?

Asked by Teemu on 20 Feb 2013

I have (double type) matrix where I have NaN values. I want to change all NaN values to 0 value. How Can I do that?

0 Comments

Teemu

Products

No products are associated with this question.

2 Answers

Answer by Azzi Abdelmalek on 20 Feb 2013
Accepted answer
A(isnan(A))=0

0 Comments

Azzi Abdelmalek
Answer by Thorsten on 20 Feb 2013
 X(isnan(X)) = 0;

0 Comments

Thorsten

Contact us