how can we add spaces in a numeric string and then change into vector form? i.e changing 11100100 into [1 1 1 0 0 1 0 0]
1 vue (au cours des 30 derniers jours)
Afficher commentaires plus anciens
how to change string 11100100 into [1 1 1 0 0 1 0 0 ]
1 commentaire
Réponse acceptée
Jos (10584)
le 26 Oct 2017
This is a neat trick for such a conversion:
s = '0111001010'
v = s - '0'
2 commentaires
Plus de réponses (0)
Voir également
Catégories
En savoir plus sur Numeric Types dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!