Error using cbarf colorbar
显示 更早的评论
Hey there, I am trying to plot a colorbar next to my contourplot like this:
m_proj('mollweid','clong',180);
m_contourf(Lon_coord,Lat_coord,Inc,36);
cbarf(Inc,36,'vertical','linear');
So I am plotting magnetic inclination for earths surface via longitude and latitude. The plot works very well but the cbarf returns the following error:
??? Error using ==> set
Bad property value found.
Object Name : axes
Property Name : 'YLim'
Values must be increasing and non-NaN.
Error in ==> ylim at 44
set(ax,'ylim',val);
Error in ==> cbarf at 224
ylim(yl)
Error in ==> jkb_script at 49
cbarf(Inc,36,'vertical','linear');
There is a script of my professor which uses cbarf quite similar so it shouldn't be very wrong. Maybe the projection applies settings to the axes that confuse cbar? Thanks for your help!
Jakob
1 个评论
Image Analyst
2011-11-29
cbarf? Isn't that what happens when you go to a college party?
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Contour Plots 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!