txt file to matrix

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

0 votos

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 Data Type Conversion en Centro de ayuda y File Exchange.

Etiquetas

Preguntada:

el 26 de Mzo. de 2012

Community Treasure Hunt

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

Start Hunting!

Translated by