Global Index (short | long) | Local contents | Local Index (short | long)
Start with SLP:
This script calls | |
---|---|
clean cd /home/disk/tao/data/nmc.reanalysis/monthly load slp_5x5_deg_ave.mat filin = 'slp.mon.mean.nc'; tim = 643:651; varn = 'slp'; lims = [0 360 -90 90]; lev = 1; [data, lat, lon, time] = getnc2(filin, varn, lims, lev, tim); [ntim, nlat, nlon] = size(data); slp_5x5 = [slp_5x5; repmat(NaN, [ntim floor(nlat/2) floor(nlon/2)])]; for i = tim; i tem = squeeze(data(i-min(tim)+1,:,:)); for j = 1:floor(nlat/2); ind1 = 2*(j-1)+[1:2]; for k = 1:floor(nlon/2); ind2 = 2*(k-1)+[1:2]; slp_5x5(i,j,k) = squeeze(mean(mean(tem(ind1, ind2)))); end end end cd /home/disk/tao/data/nmc.reanalysis/monthly descr = ['5x5 degree averages of monthly NMC reanalysis SLP,'; 'years 1948 -- June 2001. ']; save slp_5x5_deg_ave.mat slp_5x5 lon_5x5 lat_5x5 lims descr % Now, SST: load sst_5x5_deg_ave.mat filin = 'air.mon.mean.sfc.48mar01.nc'; tim = 625:639; varn = 'air'; lims = [0 360 -90 90]; lev = 1; [data, lat, lon, time] = getnc2(filin, varn, lims, lev, tim); [ntim, nlat, nlon] = size(data); sst_5x5 = [sst_5x5; repmat(NaN, [ntim floor(nlat/2) floor(nlon/2)])]; for i = tim; i tem = squeeze(data(i-min(tim)+1,:,:)); for j = 1:floor(nlat/2); ind1 = 2*(j-1)+[1:2]; for k = 1:floor(nlon/2); ind2 = 2*(k-1)+[1:2]; sst_5x5(i,j,k) = squeeze(mean(mean(tem(ind1, ind2)))); end end end cd /home/disk/tao/data/nmc.reanalysis/monthly descr = ['5x5 degree averages of monthly NMC reanalysis SST,'; 'years 1948 -- March 2001. ']; save sst_5x5_deg_ave.mat sst_5x5 lon_5x5 lat_5x5 lims descr % Now, UWNDD: load uwnd_5x5_deg_ave.mat filin = 'uwnd_925mb.mon.mean.00Jun01.nc'; tim1 = 1:18; tim = 625:642; varn = 'uwnd'; lims = [0 360 -90 90]; lev = 925; [data, lat, lon, level, time] = getnc2(filin, varn, lims, lev, tim1); data = squeeze(data); [ntim, nlat, nlon] = size(data); uwnd_5x5 = [uwnd_5x5; repmat(NaN, [ntim floor(nlat/2) floor(nlon/2)])]; for i = tim; i tem = squeeze(data(i-min(tim)+1,:,:)); for j = 1:floor(nlat/2); ind1 = 2*(j-1)+[1:2]; for k = 1:floor(nlon/2); ind2 = 2*(k-1)+[1:2]; uwnd_5x5(i,j,k) = squeeze(mean(mean(tem(ind1, ind2)))); end end end cd /home/disk/tao/data/nmc.reanalysis/monthly descr = ['5x5 degree averages of monthly NMC reanalysis UWND,'; 'years 1948 -- June 2001. ']; save uwnd_5x5_deg_ave.mat uwnd_5x5 lon_5x5 lat_5x5 lims descr