read a text file
Ältere Kommentare anzeigen
Hi
I need to make a matrix with the text file attached below.
I've considered 'fscanf' and 'readtable'.
But I faced 2 problems.
Some of rows have 8 elements while others have 10.
Also, there are blank cells and I don't know how to handle this to make it 0.
Thanks.

1 Kommentar
Walter Roberson
am 4 Nov. 2020
See https://www.mathworks.com/help/matlab/ref/matlab.io.text.fixedwidthimportoptions.html
Akzeptierte Antwort
Weitere Antworten (0)
Kategorien
Mehr zu Text Data Preparation finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


