Legend entries independent of drawn lines
1 view (last 30 days)
Show older comments
Hey everybody,
as seen in the attached picture I have some lines with two varying parameters c and d. c is represented by a different color and d as a different line style. Now I have 9 entries. I would rather have a legend with just the color X represents c = ... and line style Y represents d = ... That would give me only 6 entries. Is this possible in any way? It is not that bad in the picture, but gets annoying with more lines that I have
At the moment I create my legend like this:
for n = 1:size_c
for k = 1:size_d
legendInfo{:,size_d*(n-1) + k} = ['$c_{AVB}$ = ' num2str(c(n)) ' $\frac{N}{m}$, ' '$d_{AVB}$ = ' num2str(d(k)) ' $\frac{Ns}{m}$'];
end
end
legend(legendInfo,'Interpreter','latex');
0 Comments
Answers (0)
See Also
Categories
Find more on Legend in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!