; ; "uv300.nc data file is in $NCARG_ROOT/lib/ncarg/data/cdf ; load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl" begin filename = "uv300.nc" a = addfile(filename,"r") u = a->U(0,:,:) ; read first time step printVarSummary(u) uavg = dim_avg(u) ; average across all longitudes for every latitude wks = gsn_open_wks("x11","xy") ;---Set some resources res = True res@gsnMaximize = True res@tiMainString = filename ; main title res@xyLineColor = "DodgerBlue" res@xyLineThicknessF = 7.0 ; 3 times as thick res@xyDashPattern = 3 ; 0 is the default ; plot = gsn_csm_xy(wks,u&lat,u(:,5),res) plot = gsn_csm_xy(wks,u&lat,uavg,res) end