Labeling only specific contour lines in a contour plot
15 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
MathWorks Support Team
am 16 Dez. 2016
Beantwortet: MathWorks Support Team
am 16 Dez. 2016
I have a contour plot with many lines. However, I want to label only some of those lines. How do I do this?
Akzeptierte Antwort
MathWorks Support Team
am 16 Dez. 2016
For labeling only some of the lines in a contour plot, define a vector with the lines you want to label, and give that as an input argument to the "clabel" function.
As an example :
% Generate labels only for contour lines 2 and 6
[x,y,z] = peaks;
[C,h] = contour(x,y,z);
v = [2,6];
clabel(C,h,v);
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Contour Plots 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!