Azzera filtri
Azzera filtri

split character strings into cell arrays without delimiter

4 visualizzazioni (ultimi 30 giorni)
I have a 10 x 100 character array that I would like to change into a 10 x 100 cell array.
e.g.
'AEADHF'
'TYESDF'
into
'A' 'E' 'A' 'D' 'H' 'F'
'T' 'Y' 'E' 'S' 'D' 'F'

Risposta accettata

Voss
Voss il 21 Nov 2023
ch = ['AEADHF';'TYESDF']
ch = 2×6 char array
'AEADHF' 'TYESDF'
C = num2cell(ch)
C = 2×6 cell array
{'A'} {'E'} {'A'} {'D'} {'H'} {'F'} {'T'} {'Y'} {'E'} {'S'} {'D'} {'F'}

Più risposte (0)

Categorie

Scopri di più su Characters and Strings in Help Center e File Exchange

Prodotti


Release

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by