Don't show "NaN" in uitable ,if there not value in a table cell.
4 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1118905/image.png)
0 commentaires
Réponse acceptée
Ankit
le 9 Sep 2022
Below method will remove NaN with a variable as ' '. But for this you need to convert your array it into cell array first
A = [1 2 NaN 3 4 NaN 5] ;
Acell = num2cell(A);
idx = cellfun(@(C) all(isnan(C)), Acell);
Acell(idx) = {' '};
Plus de réponses (1)
Voir également
Catégories
En savoir plus sur NaNs 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!