I wish to add a variable to a legend which I have discovered how to do, however I would like to have the initial element within the legend untouched and add the variable to the second parameter within the legend.
This piece of code displays what I want displayed in the legend next to the bottom element. I also want to add the initial set of points above this one.
Legr2Lin_R5 = compose('y = bx^m, r^2 = %.3g', r2Pwr_R5);
If I use this piece of code I get both elements within the legend, but no variable value for the second element as in the code above.
legend('Data Points','y = bx^a')
The question, how do I have both elements displayed in the legend, but also have the variable value displayed next to the second element within the legend?
I have tried a couple of things, but nothing is coming close to working.