<div dir="ltr"><div class="gmail_default" style="font-size:small">​Hi Andrew,</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Whenever you have data in native projection, which is data that has already been projected into a particular area on a map, AND you have set tfDoNDCOverlay to True, you have to be careful about zooming in on it. The &quot;res@tfDoNDCOverlay = True&quot;, tells NCL that the data has already been projected, so assumes that you&#39;ve already done the work of setting the map projection parameters.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">This works for the original data, of course. However, when you zoom in on the map, you also have to zoom in on the data itself, because NCL has no way of knowing how to correctly subset your data in order to have it line up with your new map projection parameters.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">There are two things you can do to get the zoom to be correct:</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">1) If you want to stay in the native map projection that&#39;s defined on the file, you will need to subset your data to match the area of interest. </div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">2) If you don&#39;t care about staying in the native map projection, then you can read the 2D lat/lon arrays off the file and pass these to the plotting procedure so NCL will know how to correctly zoom in on your data.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Please see the &quot;dataonmap_zoom_10.ncl&quot; example that I just added to the &quot;Plotting data on a map&quot; page, which shows both methods:</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default"><a href="http://www.ncl.ucar.edu/Applications/plot_data_on_map.shtml#ex10zoom">http://www.ncl.ucar.edu/Applications/plot_data_on_map.shtml#ex10zoom<br></a></div><div class="gmail_default"><br></div><div class="gmail_default">You can compare this to the example above it, which plots the original data:</div><div class="gmail_default"><br></div><div class="gmail_default"><a href="http://www.ncl.ucar.edu/Applications/plot_data_on_map.shtml#ex10">http://www.ncl.ucar.edu/Applications/plot_data_on_map.shtml#ex10<br></a></div><div class="gmail_default"><br></div><div class="gmail_default">--Mary</div><div class="gmail_default"><br></div><div class="gmail_default"><br></div><div class="gmail_default" style="font-size:small"><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Mar 13, 2017 at 2:16 PM, Andrew Schwartz <span dir="ltr">&lt;<a href="mailto:aschwa@ucar.edu" target="_blank">aschwa@ucar.edu</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I am working on zooming in on Texas/ New Mexico for a case study 
that I&#39;m performing with the WRF. I have the actual map zoomed in to the
 region that I want, but the plotting of the qnifa variable doesn&#39;t 
scale and stays as if the map projected is that of the CONUS. Can anyone
 tell me what I&#39;m doing wrong? I have attached two plots to illustrate the issue. The plot of the CONUS is correct in its placement and areas of qnifa, the zoomed plot is not.<br><br>Thanks in advance for the help!<br><br>-Andrew<br><br>load &quot;$CSM/gsn_code.ncl&quot;<br>load &quot;$CSM/gsn_csm.ncl&quot;<br>load &quot;$CSM/contributed.ncl&quot;<br><br>begin<br>  res = True<br>  res@cnLinesOn          = False<br>  res@cnFillOn           = True               ; color plot desired<br>  res@cnLineLabelsOn     = False              ; turn off contour lines<br>  res@cnInfoLabelOn       = False           ; turn off cn info label<br><br>  res@mpGeophysicalLineColor= &quot;black&quot; ; color of continental outlines<br>  res@mpPerimOn             = True ; draw box around map<br>  res@mpPerimDrawOrder      = &quot;PostDraw&quot;<br>  res@mpGridLineDashPattern = 2 ; lat/lon lines as dashed<br>  res@mpOutlineBoundarySets = &quot;GeophysicalAndUSStates&quot;<br>  res@mpUSStateLineColor    = &quot;black&quot;<br><br>  cmap = read_colormap_file(&quot;CBR_drywet<wbr>&quot;)<br><br>  ff = addfile(&quot;<a href="http://wrfout.nc" target="_blank">wrfout.nc</a>&quot;,&quot;r&quot;)<br>  if (ff@MAP_PROJ .eq. 1) then<br>    res@mpProjection        = &quot;LambertConformal&quot;<br>  end if<br>  res@mpLambertMeridianF    = ff@CEN_LON<br>  res@mpLambertParallel1F   = ff@TRUELAT1<br>  res@mpLambertParallel2F   = ff@TRUELAT2<br>  res@gsnAddCyclic          = False<br>  res@tfDoNDCOverlay        = True<br>  res@mpLimitMode           = &quot;Corners&quot;<br>  xlats = ff-&gt;XLAT<br>  xlons = ff-&gt;XLONG<br>  ijdim = dimsizes(xlats)<br>  imax = ijdim(1)<br>  jmax = ijdim(2)<br>  res@mpLeftCornerLatF      = 37<br>  res@mpLeftCornerLonF      = -110<br>  res@mpRightCornerLatF     = 28<br>  res@mpRightCornerLonF     = -96<br>  res@mpFillOn                  <wbr>  = True<br><br>  res@cnLevelSelectionMode = &quot;ExplicitLevels&quot;<br>  res@cnLevels  = (/4E6,8E6,16E6,32E6,64E6/)<br>  res@cnFillColors = (/7,6,5,4,3,2/)<br>  res@cnMissingValFillColor = 13<br><br>  hgt = ff-&gt;QNIFA(0,0,:,:)<br><br> 
 res@tiMainString = &quot;Ice-Friendly Aerosol Concentration at Lowest Model 
Level  ~C~   W/ IC_BC and -30% SMOIS 19:00Z February 24, 2007&quot;<br>  res@tiMainFontHeightF = 0.015<br>  res@gsnRightString = &quot; &quot;<br>  res@gsnLeftString = &quot; &quot;<br>  res@gsnMaximize      = True<br>  res@gsnFrame     = False            ; Don&#39;t advance the frame<br><br>    wks = gsn_open_wks(&quot;png&quot;,&quot;qnifa_plot<wbr>&quot;)<br>    gsn_define_colormap(wks, &quot;CBR_drywet&quot;)<br><br>    map = gsn_csm_contour_map(wks,hgt,re<wbr>s)<br><br>  frame(wks)<br><br>end</div>
<br>______________________________<wbr>_________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/<wbr>mailman/listinfo/ncl-talk</a><br>
<br></blockquote></div><br></div>