How to open a . txt file in Matlab that has many elements?

Asked

Viewed 5,456 times

3

When the matrix has few elements the dlmread command fucks but in the case of a high-order matrix does not. I would like to have access to the matrix columns.

  • Provide more details friend, Show the matrix with few elements and the with many elements!

  • The matrix is in a file . txt coming from a simulation. When I try to open it with the command I have always used, dlmread('filename.txt'), the message appears in Workspace: Too Many Elements. I would like to know another command that I can use to access the columns of the matrix.

1 answer

1

Try to use the tblread instead of dlmread!

You can read files with this structure:

Latitude » Longitude » City
42.3584  » -71.0598  » Boston
40.4167  » -3.7003   » Madrid
41.8955  » 12.4823   » Rome

And you can still use delimiters to find the right positions!

Source for research and understanding of the cited command!

Browser other questions tagged

You are not signed in. Login or sign up in order to post.