Borrar filtros
Borrar filtros

How to reshape into 1-D array??????????reply soon plz

1 visualización (últimos 30 días)
Talat
Talat el 7 de Mayo de 2011
Hello! i wana to reshape the following (16-bit)one column and 9-rows into 1-D array...
{ B=
0000000000110000
0000000000111101
0000000000111110
0000000001000000
0000000001000100
0000000001001001
0000000001001010
0000000001001110
0000000001011100
Bin_array=reshape(B,1,size(B, 1)*size(B,2))
This code return col-wise concatnated array, but i wana a reshaped array that concatnate row-wise, mean first row then second row then third and so on..... by considering it only one column. plzzz help me and make correction in given code
thanx
  1 comentario
Oleg Komarov
Oleg Komarov el 7 de Mayo de 2011
Don't get it wrong, B is a char array of 9 rows by 16 columns.

Iniciar sesión para comentar.

Respuesta aceptada

bym
bym el 7 de Mayo de 2011
Bin_array=reshape(B',1,[])'
  1 comentario
Walter Roberson
Walter Roberson el 7 de Mayo de 2011
That final ' should not be there as Talat does want a row output.

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Image Processing Toolbox 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