Borrar filtros
Borrar filtros

how to seperate column contains many val

1 visualización (últimos 30 días)
Amgad Abuwarda
Amgad Abuwarda el 13 de Sept. de 2018
Comentada: Amgad Abuwarda el 13 de Sept. de 2018
Hez guys As you can see in the screenshot, it's a column in a table called TABLE1 I want to seperate these values into many columns ( I don't know the number of columns because as you see it's not the same for all rows how to do this? thanks
  3 comentarios
Guillaume
Guillaume el 13 de Sept. de 2018
it has many variables separated by space
You're confusing the display, where matlab does use a space to separate elements of a vector, and the storage. Internally, everything is stored as numbers one after the other (for a given row) of X.
It is not possible to create a table where the rows have different number of variables, so if you were to split each vector into individual columns you'd have to pad the shorter one with something (possibly NaN). I wouldn't recommend that as it would more likely make further processing harder not easier.
Can you explain what you want to do with the data, and why you want it split?
Amgad Abuwarda
Amgad Abuwarda el 13 de Sept. de 2018
it was stuct file then i converted it to table using struct2table. I have attached the stuct file, you can see the field X, it's the x=coordinate of some points, and you can see every row has different number of coordinates, Now i want for example to search for a specific x=coordinate in this field , but i think it's easier to separate it first then search

Iniciar sesión para comentar.

Respuestas (0)

Categorías

Más información sobre Data Type Conversion 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