[ncl-talk] Lambert Conformal Projection Offset from Map

John H. hinsberj at yahoo.com
Tue Jan 29 23:50:35 MST 2019


Hello-
I'm trying to plot the National Blend Model (NBM) from NOAA. I can plot the entire domain using mpLimitMode="Corners"and it looks beautiful!  However, when I "zoom in" to the area I'm interested in, the data is plotted clearly offset from the map (image attached).
I'm using NCL Version 6.5.0, and am at my wit's end! 

printVarSummary(t)Variable: tType: floatTotal Size: 14979860 bytes            3744965 valuesNumber of Dimensions: 2Dimensions and sizes: [ygrid_0 | 1597] x [xgrid_0 | 2345]Coordinates:             ygrid_0: [19.229..53.05043]            xgrid_0: [-126.2766..-69.20848]Number Of Attributes: 14  initial_time : 01/28/2019 (03:00)  forecast_time_units : hours  forecast_time : 1  level :  2  level_type : Specified height level above ground (m)  parameter_template_discipline_category_number : ( 0, 0, 0, 0 )  parameter_discipline_and_category : Meteorological products, Temperature  grid_type : Lambert Conformal can be secant or tangent, conical or bipolar  coordinates : gridlat_0 gridlon_0  _FillValue : 9999  units : K  long_name : Temperature  production_status : Operational products  center : US National Weather Service - NCEP (WMC)

My code: begin
fils=systemfunc("ls *.nc")a=addfile(fils(0),"r")
t=a->TMP_P0_L103_GLC0lat2d=a->gridlat_0lon2d=a->gridlon_0lat=lat2d(:,0)lon=lon2d(0,:)t&ygrid_0=latt&xgrid_0=lont at _FillValue=9999
wks=gsn_open_wks("png","Temp")res = Trueres at mpProjection = "LambertConformal"
res at mpFillOn = Falseres at cnFillOn = Trueres at cnLinesOn = Falseres at cnFillPalette = "amwg256"res at tfDoNDCOverlay = Trueres at gsnAddCyclic = False
res at mpMinLatF = 40.0res at mpMaxLatF = 50.0res at mpMinLonF = -125.0res at mpMaxLonF = -105.0res at gsnMaskLambertConformal = True
plot = gsn_csm_contour_map(wks,(t({40:50},{-125:-105})),res)
end




Regards-John
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190130/617576fa/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Temp.png
Type: image/png
Size: 84141 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20190130/617576fa/attachment.png>


More information about the ncl-talk mailing list