Info

This question is closed. Reopen it to edit or answer.

How do I import a list with 30 rows and 5 columns from a notepad file? The column has both strings and floats.

1 view (last 30 days)
I want to store the list in an array. A sample row looks like this
BL - A - 0.02 - 20 - Corrective
Using the Import wizard, or the textscan, I was not able to read the above code. It threw me error saying it is not importable.
Please suggest me the method for this.

Answers (1)

Image Analyst
Image Analyst on 10 Apr 2013
Try looping with fgetl() and then using strfind() to find the "valid" lines of text that you want to use sscanf() on.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!