char array to pick

2 visualizaciones (últimos 30 días)
dmfwlansejr
dmfwlansejr el 29 de Jul. de 2021
Respondida: Akira Agata el 29 de Jul. de 2021
a =
5×3 char array
'25A'
'107'
'28E'
'2B1'
'2EC'
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
I want to pick
a(1,2:3)
a(2,2:3)
:
:
a(5,2:3)
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
I want to convert to following. No 'for', 'while' etc... use
'5A'
'07'
'8E'
'B1'
'EC'

Respuesta aceptada

Akira Agata
Akira Agata el 29 de Jul. de 2021
The solution should be:
b = a(:,2:3);

Más respuestas (0)

Categorías

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