[ncl-talk] Fw: Can't read values to plot

gurbrinder aulakh gurbrinderaulakh at yahoo.co.in
Mon May 29 03:27:17 MDT 2017



     On Sunday, 28 May 2017 8:50 PM, gurbrinder aulakh <gurbrinderaulakh at yahoo.co.in> wrote:
 

 I want to compute wind divergence reading u and v wind components but I am getting the following warnings when I run the script.Plot is also not as expected... Please help tried everything from the earlier queries but not finding any solution.... Am I reading the correct values....Thanks in advance..



warning:IrTransInitialize: trYCoordPoints contains invalid coordinate array: defaulting trYAxisType to LinearAxiswarning:AutoComputeMajorTickMarks: min and max are so close together or so far apart that arithmetic error may cause problems, proceed at own riskwarning:ComputeMinorTickMarks: The distance between major tickmarks is so close or so far apart that arithmetic error may cause problems determining the accurate locations of minor tickmarkswarning:AutoComputeMajorTickMarks: min and max are so close together or so far apart that arithmetic error may cause problems, proceed at own riskwarning:ComputeMinorTickMarks: The distance between major tickmarks is so close or so far apart that arithmetic error may cause problems determining the accurate locations of minor tickmarkswarning:StreamlinePlotInitialize: coordinate spacing is irregular; linear spacing only possible using index coordinates for Y Axiswarning:IrTransInitialize: trYCoordPoints contains invalid coordinate array: defaulting trYAxisType to LinearAxis




*************************************************;; These files are loaded by default in NCL V6.2.0 and newer; load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"   ; load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl"    ; load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" ;*************************************************begin
  uf = addfile("uwind500.nc","r")      vf = addfile("vwind500.nc","r")         u   = uf->UGRD_500_ISBL(0,:,:)    v   = vf->VGRD_500_ISBL(0,:,:)
lat = uf->u&YCells                                    lon = uf->v&XCells
u!0="lat"u!1="lon"
u&lat at units="degrees_north"u&lon at units="degrees_east"
printVarSummary(u);  div = uv2dvG_Wrap(u,v)                ; u,v ==> divergence
  dv2uvg(div,u,v) ; div  ==> divergent  wind components
   u at long_name  = "Zonal Divergent Wind"  u at units      = u at units  v at long_name  = "Meridional Divergent Wind"  v at units      = v at units
;*************************************************; plot results;*************************************************      wks  = gsn_open_wks("png","wind123")           ; send graphics to PNG file                                               res                 = True  res at vcRefMagnitudeF = 3.                    ; make vectors larger  res at vcRefLengthF    = 0.050                 ; reference vector length  res at vcGlyphStyle    = "CurlyVector"         ; turn on curly vectors  res at vcMinDistanceF  = 0.012                 ; thin the vectors
  res at gsnLeftString   = "Divergent Wind"                                              ; plot 1st time step  plot= gsn_csm_vector_map(wks,u(:,:),v(:,:),res)
end


   
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170529/97893e2f/attachment.html 


More information about the ncl-talk mailing list