[ncl-talk] warning:_NhlCreateSplineCoordApprox: Attempt to create spline approximation for X axis failed: consider adjusting trXTensionF value

grace 313695096 at qq.com
Sat Apr 8 04:45:11 MDT 2017


Hi:
  All,I have write a script to read and trmm 3B42 data ,but it appears warning :


 (0)     gsn_add_cyclic: Warning: The range of your longitude coordinate array is at least 360.
(0)     You may want to set gsnAddCyclic to False to avoid a warning
(0)     message from the spline function.
warning:_NhlCreateSplineCoordApprox: Attempt to create spline approximation for X axis failed: consider adjusting trXTensionF value
warning:IrTransInitialize: error creating spline approximation for trXCoordPoints; defaulting to linear


And there is no contour appeared on the plot



This is my script:
   ;
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl"
load "$NCARG_ROOT/lib/ncarg/nclscripts/wrf/WRFUserARW.ncl"


begin


  a = addfile("/backup/hl/z_20min/2010.nc","r")




; We generate plots, but what kind do we prefer?
;  type = "x11"
  type = "pdf"
; type = "ps"
; type = "ncgm"
  wks = gsn_open_wks(type,"trmmPrecip2010_0808")
; get data
pcp  = a->PCP
lat  = a->LAT
lon  = a->LON1_1441
pcp_sum=dim_sum_n(pcp(0:8,:,:),0)


pcp_sum!0="lat"
pcp_sum!1="lon"
pcp_sum&lat=lat(0:399)
pcp_sum&lon=lon(0:1440)
printVarSummary(pcp_sum)


;printVarSummary(pcp1)


; Set some basic resources

res = True
  res at gsnDraw  = False
  res at gsnFrame = False
 res at cnLinesOn = False
res at lbLabelBarOn        = False
res at cnInfoLabelOn       = False
res at cnLineLabelsOn      = False
res at mpPerimOn   = True
res at gsnMaximize=True
res at pmTickMarkDisplayMode   = "Always"
res at gsnDraw   = False        ; don't draw yet
res at gsnFrame  = False


res at mpGeophysicalLineColor = "Black"
res at mpNationalLineColor    = "Black"
res at mpDataSetName         = "Earth..4"
res at mpDataBaseVersion     = "MediumRes"
res at mpOutlineSpecifiers = ("China:states")
res at mpNationalLineThicknessF= 0.1
res at mpOutlineDrawOrder    = "PostDraw"
res at mpLimitMode = "LatLon"    ; Limit the map view.
res at mpMinLonF   = 104.8
res at mpMaxLonF   = 112
res at mpMinLatF   = 31.9
res at mpMaxLatF   = 39.3



 plot=gsn_csm_contour_map(wks,pcp_sum,res)
       shp_name    = "/public/home/huanglei/map/shaanxi_city_l.shp"
       lnres                  = True
        lnres at gsLineColor      = "black"
        lnres at gsLineThicknessF = 1.5
 id = gsn_add_shapefile_polylines(wks,plot,shp_name,lnres)


  txres2  = True
   txres2 at txFont  = 10
   txres2 at txFontHeightF =0.01
   txres2 at txFontColor = "Blue"
   txdum1 =gsn_add_text(wks, plot, "Xian", 108.93,34.27, txres2)
  draw(plot)
  frame(wks)
  delete(res)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;




end





My NCL version is 6.2.0.
 How can I slove the problem?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170408/1f67dcb2/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: image/jpeg
Size: 76049 bytes
Desc: not available
Url : http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20170408/1f67dcb2/attachment.jpe 


More information about the ncl-talk mailing list