How can I simplify into the line?

2 visualizaciones (últimos 30 días)
HyoJae Lee
HyoJae Lee el 15 de Mzo. de 2022
Comentada: HyoJae Lee el 15 de Mzo. de 2022
Hello!
First of all, sorry for my bad English.
This is one of my pictures that is converted into black & white image.
When I look this image in Matlab by using imread~, it is composed of 0 (black) and 255 (white) value.
When we look into the matrix in the red box, it looks like
0 0 0 0 0 0
0 255 255 0 255 255
255 255 255 255 255
255 255 255 255 255
0 255 255 255 255 0
0 0 0 0 0 0 ...
this.
But, I want to simply into a single line like
0 0 0 0 0 0
0 0 0 0 0 0
255 255 255 255 255 255
0 0 0 0 0 0
0 0 0 0 0 0...
this.
Finally, I want like this image.
So, how can I linearize this matrix? or
Is there any recommended way to do this?
Thanks,
HyoJae.

Respuesta aceptada

Walter Roberson
Walter Roberson el 15 de Mzo. de 2022
bwmorph('skel')
  1 comentario
HyoJae Lee
HyoJae Lee el 15 de Mzo. de 2022
Thanks for your fast reply!
This helps me a lot.
Appreciated,
HyoJae.

Iniciar sesión para comentar.

Más respuestas (0)

Etiquetas

Productos


Versión

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by