change dimension of data

1 visualización (últimos 30 días)
Jay Hanuman
Jay Hanuman el 20 de En. de 2017
Comentada: Adam el 20 de En. de 2017
I have data in ab with n rows and 4 columns. I made it 1*n by
ab1=ab'
then
ab2=ab1(:).'
I want it back ab2 in ab format i.e. n*4. how to do it.

Respuestas (1)

the cyclist
the cyclist el 20 de En. de 2017
reshape(ab2,n,4)
  2 comentarios
Jay Hanuman
Jay Hanuman el 20 de En. de 2017
Editada: Jay Hanuman el 20 de En. de 2017
its doing 1st n element in 1st column then next n element in next column likewise, I want that 1st 4 element in 1st row, then next 4 element in 2nd row, likewise
Adam
Adam el 20 de En. de 2017
reshape( ab2, 4, n )'

Iniciar sesión para comentar.

Categorías

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