Create a new matrix from a mapping process
Afficher commentaires plus anciens
I have mapped a set of numbers to a list of strings for example
KS = {'A','B','C'}; VS = [1:3]; x = containers.Map(KS,VS);
I have a 1 coloumn vector that looks like this
'A' 'B' 'B' 'C' 'A'
I want to create a new matrix which maps the letters to their respective numbers - so this would return 1 2 2 3 1
many thanks
Réponse acceptée
Plus de réponses (0)
Catégories
En savoir plus sur Dictionaries dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!