txt file to matrix

5 visualizaciones (últimos 30 días)
Nelly
Nelly el 26 de Mzo. de 2012
Hi there. I have txt file with data (integers). My file has 140 rows with changing number of elements(numbers) (from 6 to 12)in each row. I want to convert this data to matrix. How can you help me? thanks a lot. Nelly

Respuesta aceptada

Walter Roberson
Walter Roberson el 26 de Mzo. de 2012
What kind of matrix are you wanting? Numeric matrices must have the same number of elements in each row. Did you want the missing values to be filled in with NaN or with 0, or did you want to use a cell array?

Más respuestas (0)

Categorías

Más información sobre Cell Arrays en Help Center y File Exchange.

Etiquetas

Community Treasure Hunt

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

Start Hunting!

Translated by