Remove Whitespace & Text From Cell
8 次查看(过去 30 天)
显示 更早的评论
If I have a cell like
[0.078 ms]
How can I remove both the whitespace and 'ms' to yield the result
[0.078]
Thanks,
回答(2 个)
Kunal Kandhari
2023-1-31
3 个评论
Kunal Kandhari
2023-1-31
Hi Cesar,
You you please explain it is several thousand cell array or array of cells?
So that I can help you with that..
Can you write a dummy variable here?
Walter Roberson
2023-1-31
See https://www.mathworks.com/help/matlab/ref/matlab.io.text.delimitedtextimportoptions.setvaropts.html#d124e755396 for the import options to ignore particular prefixes or suffixes. You would detectImportOptions and setvaropts and then pass the resulting options to readtable
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 String Parsing 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!