How can I loop through a column in a sub tables and convert non-cells to cells?
Mostrar comentarios más antiguos
I have a 33x5 table (Named: Book1), each cell in the 4th column has sub table (Named: SubTable) of size Nx13.
When trying to concatinate all sub tables, I get the error below: "Cannot concatenate the table variable "Atoms" because it is a cell in one table and non-cell in another."
"Atoms" is the 13th column of the sub tables.
How can I loop through and convert all non-cells to cells in all the subtables (specifically from the 13th column)?
NOTE: In the sub tables, the 13th column "Atoms":
-The non-cells use logical have the value of 1 or 0.
-The cells have the value of 'true' or 'false'
Example of the SubTable:

6 comentarios
Dyuman Joshi
el 3 de Jul. de 2023
Please attach your data using the paperclip button and show what you have attempted yet.
Rookie Programmer
el 3 de Jul. de 2023
Editada: Rookie Programmer
el 3 de Jul. de 2023
Dyuman Joshi
el 3 de Jul. de 2023
Editada: Dyuman Joshi
el 3 de Jul. de 2023
You did not attach your data. Please attach your data.
And note that True/False are equivalent to 1/0, so the assignments in if-else condition block is redundant.
Or do you want to use the char arrays 'true' and 'false' instead of logical values?
Rookie Programmer
el 3 de Jul. de 2023
Editada: Rookie Programmer
el 3 de Jul. de 2023
Matt J
el 3 de Jul. de 2023
Sorry I cannot attach my data.
Meaning that it is proprietary? Then attach hypothetical data with the same relevant structure.
Rookie Programmer
el 3 de Jul. de 2023
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Tables en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
