Replacing NaN with blanks in a matrix

4 vues (au cours des 30 derniers jours)
alok pandey
alok pandey le 6 Jan 2020
Commenté : Ridwan Alam le 9 Jan 2020
I've a matrix which looks like the one attached. How do I replace NaNs with blank spaces without altering anything else?
Thanks in advance.

Réponses (1)

Ridwan Alam
Ridwan Alam le 6 Jan 2020
  4 commentaires
alok pandey
alok pandey le 9 Jan 2020
Thanks for the prompt reply Ridwan. So, if you open the attched mat file, you'll see that the matrix contain NaNs. I was wondering if it is possible to replace (remove) NaNs and have 'empty cells' instead. I tried fillmissing but as you said, we end up with a 'string' which I don't want.
What I was wondering is if we can we can use something like:
Phase_data(isnan(Phase_data))='empty cells';
Sorry, I'm stuck.
Ridwan Alam
Ridwan Alam le 9 Jan 2020
I was wondering if it is possible to replace (remove) NaNs and have 'empty cells' instead.
Nope, I don't think that's possible. Sorry.

Connectez-vous pour commenter.

Catégories

En savoir plus sur NaNs dans Help Center et File Exchange

Produits


Version

R2017b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by