How to combine multiple columns into array?

217 visualizaciones (últimos 30 días)
pink flower
pink flower el 2 de Sept. de 2020
Editada: per isakson el 2 de Sept. de 2020
I have 5 columns and I would like to join them and form a matrix with n rows and 5 columns. How can I do this?

Respuesta aceptada

per isakson
per isakson el 2 de Sept. de 2020
Editada: per isakson el 2 de Sept. de 2020
Two ways
array = cat( 2, col1, col2, col3, col4, col5 );
array = [ col1, col2, col3, col4, col5 ];

Más respuestas (0)

Categorías

Más información sobre Multidimensional 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