// Example HOPS script #2 // ocn_plot: Plotting data from ocean model prognostic history file // Open 1 year of prognostic ocean data (24 samples at half-month intervals) // for a 3-degree NCAR Ocean Model integration // (converted to CSM netCDF format using Frank Bryan"s filters) hopen, "/data/large1/CSM/3x3/G03-4.24/Y0989_0990_p.nc"; // Get surface (z=0.) temperature (T) and salinity (S) for first sample (t=1) SST=hget("T",z=0.,t=1,subscript=1); SSS=hget("S",z=0.,t=1,subscript=1); // Plot SST with color fill hplot,SST,fill=1; // Plot SST with color fill and contour overlay hplot,SST,fill=1,overlay=1; // As above, but using NH polar stereographic projection hplot,SST,fill=1,overlay=1,proj="nhpolar"; // As above, but using Mollweide projection hplot,SST,fill=1,overlay=1,proj="mollw"; // Get surface (z=0.) zonal velocity for first sample (t=1), and plot it SSU=hget("U",z=0.,t=1,subscript=1) hplot,SSU,fill=1 // Compute zonal mean temperature and plot it (globally) TBAR=hget("T",x="avg",t=1,subscript=1); hplot,TBAR,fill=1; // Compute Atlantic zonal mean temperature and plot it TBARA=hget("T",x="avg",hregion="atlantic",mask=1,t=1,subscript=1); hplot,TBARA,fill=1; // Get SST from file, rotate domain 180 degrees in longitude, // extract Atlantic SST, shrink domain, and plot SST SSTA=hget("T",z=0.,rotx=180.,hregion="atlantic",mask=1,shrink=1,t=1,subscript=1); hplot,SSTA,fill=1,overlay=1; // Extract sea surface salinity over the same domain as above, // from the full domain hyperslab SSS, and plot it SSSA=hsub(SSS,like=SSTA); hplot,SSSA,fill=1,overlay=1; // Compute zonal-mean SST and plot it SSTBAR= hsub(SST,x="avg"); hplot,SSTBAR; // Compute eddy SST by subtracting zonal-mean SSTANOM= hop(SST,"-",SSTBAR); // Plot it with data dependent levels (NOT the default SST contour levels) hplot,SSTANOM,fill=1,levs="";