Suppose the next variable:
B=genvarname(strcat('B',num2str(25),''));
And B will be:
B=B25;
Now, I want covert "B25" in a struct object, so I did this:
eval([B ' = struct([])']);
With that code I convert B25 (who is saved in "B") into a struct object.
Now, I want to save another struct object into B25, like this one:
A =
a1: 1
a2: 2
a3: 'a'
As you can see, A is a struct too.
Here is where I need your help, I don't know how to do something like this:
somefunction(B,A);
And stick B with A, like this:
B25.A=
a1: 1
a2: 2
a3: 'a'
Thanks!