Why do colorbar limits not match the values specified by the CAXIS function in MATLAB 7.0 (R14) when using the CONTOUR or CONTOURF function?
8 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
When I execute the following commands, the color bar limits do not match those of my contour plot:
contourf(peaks) % contour(peaks)
caxis([-2 2])
colorbar
I expected the color bar limits to range from -2 to 2, however, the limits range from -6 to 8.
Risposta accettata
MathWorks Support Team
il 27 Giu 2009
This bug has been fixed in Release 14 Service Pack 3 (R14SP3). For previous product releases, read below for any possible workarounds:
A bug in MATLAB 7.0 (R14) causes color axis limits on a graph created using the CONTOUR or CONTOURF functions to be set incorrectly.
To work around this issue, use the CONTOUR/CONTOURF function with the 'v6' switch. For example,
contourf('v6',peaks) % contour('v6',peaks)
caxis([-2 2])
colorbar
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Contour Plots in Help Center e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!