Plot multiple 2D contour plots in one 3D figure
10 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
MathWorks Support Team
il 21 Ago 2019
Risposto: MathWorks Support Team
il 28 Ago 2019
I have multiple 2D contour plots that I'd like to plot in one 3D figure one on top of the other with some distance in between each of the plots. How to do this?
Risposta accettata
MathWorks Support Team
il 28 Ago 2019
You can achieve this by modifying the 'ContourZLevel' property of the contour plots. For example, the following plots two contour plots with some distance between them in the Z-direction:
[X,Y,Z] = peaks;
hold on
[~,h] = contour(X,Y,Z,20); % plot contour at the bottom
h.ContourZLevel = -9;
[~,h] = contour(X,Y,Z,20); % plot contour at the top
h.ContourZLevel = +9;
hold off
view(3);
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Contour Plots in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!