Why do I receive an error when I create a figure containing a contour plot and a colorbar in MATLAB 7.0.4 (R14SP2)?
1 visualización (últimos 30 días)
Mostrar comentarios más antiguos
I create a figure with a contour plot and a colorbar using the following code:
load flujet
h=image(X);
hold on;
[c,hc]=contour(get(h,'cdata'),[1 1],'w','linewidth',2);
colorbar
When I do this, I get the following error message:
??? Error using ==> set
Bad value for axes property: 'YLim'
Values must be increasing and non-NaN.
Error in ==> colorbar>make_colorbar at 170
ch=scribe.colorbar(peeraxes,location,position,pvpairs{:});
Error in ==> colorbar at 137
[c,msg] = make_colorbar(peeraxes,location,position,pvpairs);
Respuesta aceptada
MathWorks Support Team
el 27 de Jun. de 2009
This bug has been fixed in Release 14 Service Pack 3 (R14SP3). For previous product releases, read below for any possible workarounds:
There is a bug in MATLAB 7.0.4 (R14SP2) that causes the COLORBAR function to incorrectly determine the upper and lower limits of the colorbar.
To work around this issue, you can do the following:
load flujet
h=image(X);
hold on;
colorbar
[c,hc]=contour(get(h,'cdata'),[1 1],'w','linewidth',2);
0 comentarios
Más respuestas (0)
Ver también
Categorías
Más información sobre Contour Plots en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!