Don't show "NaN" in uitable ,if there not value in a table cell.
10 次查看(过去 30 天)
显示 更早的评论
采纳的回答
Ankit
2022-9-9
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) = {' '};
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 NaNs 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!