change variable name in each loop
61 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Oliver Kumar
am 19 Mai 2016
Bearbeitet: Stephen23
am 25 Jun. 2019
Hello,
I'm trying do make a for loop in whicht the variable name changes for every loop. VPN1, VPN2, VPN3... (['VPN' num2str(l)]) When I do this, I get ans VPN1. But the problem is, that I dont get the variable VPN1 to which I can save more information. Can you please help me to solve that. Thanks.
Kind regards, Oliver
2 Kommentare
Akzeptierte Antwort
Stephen23
am 19 Mai 2016
Bearbeitet: Stephen23
am 25 Jun. 2019
4 Kommentare
Patrick
am 13 Feb. 2018
It would be nice to be able to answer the original question. I would like to do this to get a vast number of price series into a structure. For example, I have separate price vectors Price1, Price2, ... I want a loop that adds all of these vectors to a structure.
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Loops and Conditional Statements 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!