creating an empty cell in an array
5 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Ahmed Abdulla
le 21 Juin 2019
Commenté : Akshay Malav
le 21 Juin 2019
i have an array most made up of numbers and some are NaN i would like to make the NaN cells empty because i have a plotting function that doesnt accept NaN and when i assign it to 0 it affects the resulting graph, so im not really sure of how to make it blank with no numerical value
4 commentaires
Réponse acceptée
Akshay Malav
le 21 Juin 2019
Modifié(e) : Akshay Malav
le 21 Juin 2019
Then use this code.
A = [1 NaN 2];
B = rmmissing(A) % will remove NaN from array A
The B array wil be [1 2]
2 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Line Plots dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!