Borrar filtros
Borrar filtros

how i cab convert numbers into letters

4 visualizaciones (últimos 30 días)
Mohamuud hassan
Mohamuud hassan el 2 de Jun. de 2015
Editada: Stephen23 el 2 de Jun. de 2015
hello all how i can convert number which are stored in cell array in alphabet?
numbers12 = [3,6,12,1,1,3,26,20]
lettter={,,,,,}

Respuesta aceptada

Azzi Abdelmalek
Azzi Abdelmalek el 2 de Jun. de 2015
numbers12 ={3,6,12,1,1,3,26,20}
lettter=cellfun(@num2str,numbers12,'un',0)
  1 comentario
Stephen23
Stephen23 el 2 de Jun. de 2015
Editada: Stephen23 el 2 de Jun. de 2015
As the question gives a numeric vector, then arrayfun will also work:
>> X = [3,6,12,1,1,3,26,20];
>> arrayfun(@num2str,X,'un',0)
ans =
'3' '6' '12' '1' '1' '3' '26' '20'

Iniciar sesión para comentar.

Más respuestas (1)

Shrirang
Shrirang el 2 de Jun. de 2015
Hi , You can use num2str command. e.g. numbers12 = num2str(numbers12 ) so your number array in char Hope this helps you.

Categorías

Más información sobre Data Type Conversion 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