Editing Legend/Plotting
1 view (last 30 days)
Show older comments
I have this plot that shows the same colors and I would like add points, N=1 would be boxes, N=9 would be triangles, N=20 would be circles. As well as change each of their colors and thickness. Data is showing up in legend and I would want to take that out.
Mat_w = -.5:.5:.5;
u = s\f;
title('Case 2')
legend('N=5','N=9', 'N=20');
hold on
plot(Mat_w, u, 'g-')
xlim([-w,w])
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/607860/image.png)
0 Comments
Answers (1)
KSSV
on 5 May 2021
Try:
Mat_w = -.5:.5:.5;
u = s\f;
title('Case 2')
hold on
plot(Mat_w, u)
xlim([-w,w])
legend('N=5','N=9', 'N=20');
2 Comments
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!