matlab m_map学习总结系列10

clf;set(gcf,'color','w'); 
%清理;设置背景颜色
m_proj('oblique','lon',[-125.3 -122.6],'lat',[50.1 48.6] ,'dir','vert','aspect',0.45)
%投影
% Database 1 coastline
m_usercoast('/ocean/rich/more/mmapbase/bcgeo/PNW.mat',...
            'patch',[.8 .8 .8],'edgecolor','k');
% Database 2 river
m_usercoast('/ocean/rich/more/mmapbase/bcgeo/PNWrivers.mat',...
            'patch',[.8 .8 .8],'edgecolor','k');
%数据集水深与河流
% Elevation database in structure SOGbath
hold on; m_contourf(SOGbath.lon,SOGbath.lat,SOGbath.Z,[500 500],...
             'edgecolor','none','facecolor',[.7 .7 .7]); hold off;
%高程数据
m_grid('linewi',2,'tickdir','out','ticklen',.03,'linestyl','none','color','k');
m_northarrow(-125.4,49.7,.2,'type',2);
title({'Winter','ONDJFM',' '},'fontsize',14);

% Wind data in struct arrays - pass each parameter to M_WINDROSE as a 1xN 
% cell array of data in the order you want them plotted (ones on top later
% in list)

levels=[0:4:24];  % Binning for speeds

k=[1 15  18 6 3 19 4 5 7 8 10 9 11 12 2 13 14 16 17 ]; % change order to 
                                                       % make overlaps look nicer
%改变加载顺序
m_windrose({Winter(k).lon},{Winter(k).lat},{Winter(k).wdir},{Winter(k).wspd},...
           'size',.17,'nspeed',levels,'alpha',1);
%风的玫瑰花图
colormap(m_colmap('jet'));
caxis([0 24]);
%玫瑰花图加色
axb=m_contfbar(.8,[.6 .9],levels,levels);
axb.YLabel.String='Wind speeds m/s';
axb.YTick=levels;
%玫瑰花图的colorbar

在这里插入图片描述
加载的一些colorbar

 % This command generates the figure
 % In each subplot title is the M_COLMAP call that 
 % generated the colourmap displayed.
 %
 % Uses of these colourmaps can be seen
 % in other maps in this gallery.

 m_colmap demo

在这里插入图片描述

  • 1
    点赞
  • 14
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

早起CaiCai

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值