I want to change a name with a number in it to the number of the participant.
4 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
JamJan
am 22 Mai 2018
Kommentiert: JamJan
am 22 Mai 2018
Hello,
I want to give a number to a participant of my experiment. The number is in it's name, for example: Participant ='AG_1100 02_Porti_29'. The number of the participant is in bold, but I want Matlab to change it to 02 or just 2. So that the result is: Participant = 02.
How can I do this?
2 Kommentare
Walter Roberson
am 22 Mai 2018
What is the rule about what number should be extracted? Is it always at the same offset in the character vector? Is it always the first 2 digits after the first blank? Is it always the first group of digits after the first blank, no matter how many digits that is?
Akzeptierte Antwort
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Statistics and Machine Learning Toolbox finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!