Converting a string array into a number array

6 visualizaciones (últimos 30 días)
dzix design
dzix design el 13 de Feb. de 2021
Comentada: dzix design el 13 de Feb. de 2021
Please how can l convert '123456789' to [ 1 2 3 4 5 6 7 8 9] in MATLAB

Respuesta aceptada

KALYAN ACHARJYA
KALYAN ACHARJYA el 13 de Feb. de 2021
Editada: KALYAN ACHARJYA el 13 de Feb. de 2021
#Edited
num_str='123456789'
num_str - '0'
Result:
ans =
1 2 3 4 5 6 7 8 9
  7 comentarios
KALYAN ACHARJYA
KALYAN ACHARJYA el 13 de Feb. de 2021
Yes sir @Jan Thanks, In day time, I have answered a similar question, which first required changing num2str, so I used it here by mistake.
Your teaching is very valuable, thank you and much appreciation
dzix design
dzix design el 13 de Feb. de 2021
@jan thanks 🙏🏼

Iniciar sesión para comentar.

Más respuestas (0)

Categorías

Más información sobre Characters and Strings en Help Center y File Exchange.

Community Treasure Hunt

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

Start Hunting!

Translated by