Hello,
Please how can I change this matrix:
coord =
0 0
10928 0
6928 4000
into this: coord = coord=[0 0 10928 0 6928 4000]
i.e. I want to place the rows next to each other
I want the general form for whatever coord's size is. Usually it's going to be nx2

 Respuesta aceptada

madhan ravi
madhan ravi el 21 de Nov. de 2018
Editada: madhan ravi el 21 de Nov. de 2018

0 votos

m=[ 0 0
10928 0
6928 4000]
m=m'
m=m(:).'

3 comentarios

Hazem El Sankari
Hazem El Sankari el 21 de Nov. de 2018
Editada: madhan ravi el 21 de Nov. de 2018
Thank you so much for your quick reply!
madhan ravi's reply : Anytime :)
Hazem El Sankari
Hazem El Sankari el 21 de Nov. de 2018
Editada: madhan ravi el 21 de Nov. de 2018
Another question please:
if I want to convert the new m vector back to the old one, how can I do that?
madhan ravi's reply :
reshape(m',3,2)
Hazem El Sankari
Hazem El Sankari el 21 de Nov. de 2018
Thank you again for your quick help!

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Parallel Computing Toolbox en Centro de ayuda y File Exchange.

Preguntada:

el 21 de Nov. de 2018

Comentada:

el 21 de Nov. de 2018

Community Treasure Hunt

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

Start Hunting!

Translated by