yaozhixiong的个人博客分享 http://blog.sciencenet.cn/u/yaozhixiong

博文

matlab 同一张图多个子图共用一个colorbar

已有 28496 次阅读 2012-12-11 22:41 |个人分类:matlab|系统分类:科研笔记| MATLAB, 同一张图, 多个子图, 共用colorbar


for i=1%:276
   load([path1,num2str(i)]) ;
   sst_noaa=sst;
   load([path2,num2str(i)]) ;
   sst_model=sst;
    
   figure;
   axes('position',[.05,.1,.2,.8]) 
   contourf(sst_noaa'); caxis([-2 32])
   axes('position',[.35,.1,.2,.8])
   contourf(sst_model'); caxis([-2 32])
   axes('position',[.65,.1,.2,.8])
   contourf((sst_model-sst_noaa)');caxis([-2 32])
   
   axes('position',[.75,.1,.2,.8])
   axis off
   colorbar;caxis([-2 32])
end


https://blog.sciencenet.cn/blog-419857-641659.html

上一篇:install netcdf hdf5 antlr udunits in linux
下一篇:Too many files open; check that FILES = 20 in your CONFIG.SY
收藏 IP: 122.224.232.*| 热度|

0

该博文允许注册用户评论 请点击登录 评论 (3 个评论)

数据加载中...

Archiver|手机版|科学网 ( 京ICP备07017567号-12 )

GMT+8, 2024-10-20 18:38

Powered by ScienceNet.cn

Copyright © 2007- 中国科学报社

返回顶部