Global Index (short | long) | Local contents | Local Index (short | long)
Load level 1 and level 5 monthly temperatures
This script calls | |
---|---|
clear cd /home/disk/hayes2/dvimont/csiro/data filin = ['temp_M_L1_1000_years_new.nc']; nc = netcdf(filin, 'nowrite'); depth = nc{'depth'}(:); lat = nc{'latitude'}(:); lon = nc{'longitude'}(:); ctlim = [120 290 -45 45]; [xk, yk] = keep_var(ctlim, lon, lat); % Use years 350:450 tim = (12*350+1):(12*450); temp1 = nc{'temp'}(tim,1,yk,xk); mv = nc{'temp'}.missing_value(:); nc = close(nc); [ntim, nlev, nlat, nlon] = size(temp1); temp1(find(temp1 == mv)) = NaN * ones(size(find(temp1 == mv))); lat = lat(yk); lon = lon(xk); filin = ['temp_M_L5_1000_years_new.nc']; nc = netcdf(filin, 'nowrite'); temp5 = nc{'temp'}(tim,1,yk,xk); mv = nc{'temp'}.missing_value(:); nc = close(nc); [ntim, nlev, nlat, nlon] = size(temp5); temp5(find(temp5 == mv)) = NaN * ones(size(find(temp5 == mv))); temp1 = squeeze(temp1); [temp1, clim1] = annave(temp1); temp5 = squeeze(temp5); [temp5, clim5] = annave(temp5); % Plot equatorial Hofmoeller diagrams [xk, yk] = keep_var([120 290 -6 6], lon, lat); [bl, al] = butter(6, 2/(12*8)); tem = shiftdim(squeeze(mean2(shiftdim(temp1(:,yk,xk), 1))), 1); tem = detrend(tem); % tem1 = tem - filtfilt(bl, al, tem); tem1 = filtfilt(bl, al, tem); tem = shiftdim(squeeze(mean2(shiftdim(temp5(:,yk,xk), 1))), 1); tem = detrend(tem); % tem5 = tem - filtfilt(bl, al, tem); tem5 = filtfilt(bl, al, tem); for i = 1:2; tim1 = (i-1)*(ntim/2)+[1:ntim/2]; figure(1); figure_orient; subplot(1,4,(2*i)); colormap('pink'); contourf(lon(xk), (tim(tim1)-1)/12, tem1(tim1,:), 10); hold on; shading flat contour(lon(xk), (tim(tim1)-1)/12, tem1(tim1,:), [0 0], '-k'); hold off; axis([120 275 min(tim(tim1)-2)/12 max(tim(tim1))/12]) box on title('SFC') subplot(1,4,2*(i-1)+1); colormap('pink'); contourf(lon(xk), (tim(tim1)-1)/12, tem5(tim1,:), 10); hold on; shading flat contour(lon(xk), (tim(tim1)-1)/12, tem5(tim1,:), [0 0], '-k'); hold off; axis([120 275 min(tim(tim1)-2)/12 max(tim(tim1))/12]) box on title('Depth = 140m') end subplot(1,4,1); ylabel('Year'); cd /home/disk/tao/dvimont/matlab/CSIRO/Plots3 % Look at various depths, to see what happens first? clear cd /home/disk/hayes2/dvimont/csiro/data filin = ['temp_A_L1-10.nc']; nc = netcdf(filin, 'nowrite'); depth = nc{'depth'}(:); lat = nc{'latitude'}(:); lon = nc{'longitude'}(:); ctlim = [120 290 -45 45]; [xk, yk] = keep_var(ctlim, lon, lat); tim = 466:515; temp = nc{'temp'}(tim,:,yk,xk); mv = nc{'temp'}.missing_value(:); nc = close(nc); [ntim, nlev, nlat, nlon] = size(temp); temp(find(temp == mv)) = NaN * ones(size(find(temp == mv))); lat = lat(yk); lon = lon(xk); temp = reshape(temp, ntim, nlev*nlat*nlon); temp = detrend(temp); [bl,al]=butter(6,(2/4.5)); temp = filtfilt(bl, al, temp); temp = reshape(temp, ntim, nlev, nlat, nlon); temp = shiftdim(temp, 1); figure(1); [xk, yk] = keep_var([120 290 -8 8], lon, lat); for i = 1:4; lind = 3*(i-1)+1; tem = squeeze(mean(squeeze(temp(lind, yk, xk, :))))'; subplot(1,4,i); contourf(lon(xk), tim, tem, 10); end