Re: mask 2D lat/lon grid with 1D shapefile

From: Leif Truelsen <truelsen.leif_at_nyahnyahspammersnyahnyah>
Date: Tue Aug 27 2013 - 11:30:52 MDT

Thank you for bringing my attention to example 11. Unfortunately, I don't
think this duplicates my problem. My issue is that my gridded data (e.g.,
u-winds in this example) are on a rotated grid (rlat (y), rlon (x)) that
are linked to lat2d (x,y) lon2d (x,y) variables. The example dataset is in
a 1D grid. I need to mask the rotated grid using shapefiles (not all
rectangular) that are in a 1D lat/lon coordinate system. I think that the
answer to my problem involves using the getind_latlon2d function, but I
have yet to figure this out.

Kind regards,
Leif

On Mon, Aug 26, 2013 at 10:37 PM, <mgehne@ucar.edu> wrote:

> Hi Leif,
>
> I just had a similar problem recently. Example 11 deals with masking from
> a shapefile
> with 2d lat/lon coordinates.
>
> http://ncl.ucar.edu/Applications/Scripts/shapefiles_11.ncl
>
> I hope this helps,
> Maria
>
> > Hi all,
> >
> > I am looking to extract an area weighted average of gridded data using a
> > shape file. I am following the basic procedure of the shapefiles_9.ncl
> > example (http://www.ncl.ucar.edu/Applications/Scripts/shapefiles_9.ncl).
> > Basically, it reads the 1D lat/lon ranges from the shapefile and uses
> > these ranges to mask the original 1D gridded data.
> >
> > Like the example, I have a shapefile in a geographic projection with
> > single
> > dimension x and y values (in degrees). My problem is that my gridded
> data
> > is in a rotated lat/lon grid (time,y,x). The longitude and latitude
> > variables both have two dimensions (y, x). I can't seem to wrap my head
> > around how to mask these data using a shapefile in a standard 1D grid.
> > Any
> > help would be gratefully received.
> >
> > Best,
> > Leif
> > _______________________________________________
> > 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 Tue Aug 27 11:31:03 2013

This archive was generated by hypermail 2.1.8 : Fri Aug 30 2013 - 14:04:57 MDT