第一句
clear;close all;clc;
载入数据
load('');
hgt=ncread('hgt.mon.mean.nc','hgt');z500(1:144,1:73,1:792)=hgt(1:144,1:73,6,1:792);
lon1=ncread('hgt.mon.mean.nc','lon');
lat1=ncread('hgt.mon.mean.nc','lat');
时间距平
for i=1:144
for j=1:73
for k=1:12
z1(i,j,k:12:792)=z500(i,j,k:12:792)-mean(z500(i,j,k:12:792));
end
end
end
清空变量
clear z3;clear z1;
极地投影
addpath d:/m_map/
m_proj('stereographic','lat',90,'long',180,'radius',70);
m_coast('patch',[1 1 1],'edgecolor','k','linewidth',1.5);
m_grid('xtick',6,'yticklabel','','tickdir','in','linest','--','linewidth',0.2);
hold on
[c,h]=m_contour(lon1,lat1,c3',[10:10:100],'r-','linewidth',1.5);
% clabel(c,h)
hold on
[c1,h1]=m_contour(lon1,lat1,c3',[-100:10:-10],'b-','linewidth',1.5);
% % clabel(c1,h1)
hold on
坐标
set(gca,'LineWidth',2,'FontSize',12,'Ylim',[-90,90],'Xlim',[0,360],'clim',[-35,45]...
,'XTick',[0:60:360],'XTicklabel',{'0','60E','120E','180','120W','60W','0'}...
,'YTick',[-90:30:90],'YTicklabel',{'-90S','-60S','-30S','EQ','30N','60N','90N'});
分图
subplot(2,2,1)
等值线
[c,h]=contour(lon1,lat1,c1');
回归
[b2,bint,r,rint,stats2]=regress(q2',[ones(k2,1) p2']);