0001
0002
0003
0004
0005
0006
0007
0008 cdf='ecom.cdf';
0009
0010
0011 v=version;if(str2int(v(1))<5),disp('You need at least Matlab 5!'),return,end
0012
0013
0014
0015
0016 tind=1;
0017 var='temp';
0018 depth=-2;
0019
0020 [t,x,y,jd1]=zslice(cdf,var,tind,depth);
0021 [w,x,y]=zsliceuv(cdf,tind,depth);
0022
0023
0024
0025
0026
0027
0028 pslice(x/1000,y/1000,t,[10 25],'Degrees C');...
0029 psliceuv(x/1000,y/1000,w,3,20,'black');...
0030 date_str=greg2str(gregorian(jd1));...
0031 title(['Slice of ' var ' at z = ' int2str(depth) ' : ' date_str]);...
0032 xlabel('km');ylabel('km');
0033
0034
0035 figure;
0036
0037
0038 tind=2
0039 jindex=30
0040 var='salt';
0041 [s,x,z]=jslice(cdf,var,tind,jindex);
0042
0043
0044 contourf(x,z,s);
0045 colormap(jet);...
0046 title(['Slice of ' var ' at j = ' int2str(jindex) ', tstep = ' int2str(tind)]);
0047 ylabel('Depth (m)');xlabel('Distance Offshore (km)')
0048