Re: Plotting partial data

From: Dennis Shea <shea_at_nyahnyahspammersnyahnyah>
Date: Mon Mar 29 2010 - 20:50:37 MDT

You need to be more specific.

say x(time,lat,lon) ... the following may work for you

   latS = -20
   latN = 50
   lonE = 30
   lonW = 110

   res@mpMinLatF = latS ; range to zoom in on
   res@mpMaxLatF = latN
   res@mpMinLonF = lonE
   res@mpMaxLonF = lonW

   res@mpCenterLonF = (lonE+lonW)*0.5 ; optional
   res@pmTickMarkDisplayMode = "Always"; use NCL default lat/lon labels

   do nt=0,ntim-1
      plot = gsn_csm_contour_map_ce(wks,x(nt,:,:), res)
   end do

Tong Qi wrote:
> Hello,
>
> I was wondering if there is any way for NCL to automatically filter out
> parts of a plotted data field when only a certain subset of the data is
> plotted. For example, if I plot only the western hemisphere vs. the
> entire globe, since NCL was assigned the full data, it will adjust its
> labels to include all values from the entire globe, even if they are not
> present in the area of interest. I know one way is to first look at the
> data, then assign only the subset that I am interested in, such as
>
> data=file->data(0:179,:)
>
> to correspond with
>
> res@mpMaxLonF=0
>
> This would ensure that values outside of the area of interest are not
> included in the plot, but the situation becomes tricky if the file uses
> non-standard latitude/longitude mappings and I want to subset a more
> precise area rather than just a hemisphere. I am hoping there is some
> sort of automatic solution for subset plots.
>
> Thanks,
> -Tong
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Mar 29 20:50:43 2010

This archive was generated by hypermail 2.1.8 : Thu Apr 01 2010 - 11:31:45 MDT