[ncl-talk] Using merged shapefiles to create PRISM data subset

Mary Haley haley at ucar.edu
Wed Dec 19 16:06:06 MST 2018


Hi Toni,

Your shapefile has just one feature and several segments for that feature.
Usually the shapefiles we see have several features and several segments
for each feature. Your shapefile is a little unusual, but not unheard of.
Unfortunately, the examples we have all do the averaging across shapefile
*features* and not shapefile *segments*.

This doesn't mean you can't do it with NCL.  See the attached plot, where I
contoured some dummy 2D data over the area of interest and then generated a
second plot where the values were averaged based on whether they fell
inside one of these segments.  Is this what you are trying to accomplish?
If so, I'll clean up the code and send it to you.

--Mary

On Wed, Dec 19, 2018 at 1:26 PM Toni Klemm <toni-klemm at tamu.edu> wrote:

> Hello All,
>
> I am trying to use a shapefile of merged counties in the western Great
> Plains to create a spatial subset of temperature and precipitation data and
> calculate averages and totals for those counties as a whole. However, the
> data subset doesn't look anything like the shapefile (see the Panoply
> screenshot). I attached the shapefile as GIS files and screenshot.
>
> My guess is that NCL gets confused about the disconnected-yet-combined
> counties and doesn't know how to process a shapefile like that. Does anyone
> know what I can do to make this work? Can I manipulate the shapefile data
> in QGIS somehow so NCL understands it? Alternatively I could process each
> county by itself and then average the results. But there are over 100
> counties, which would take a very long time.
>
> I appreciate any help!
>
> Thank you very much,
> Toni
>
>
>
> *Toni Klemm, Ph.D.*Postdoctoral Research Associate
> Department of Ecosystem Science and Management
> College of Agriculture and Life Sciences
> Texas A&M University, College Station, TX
> Contributor to the Early Career Climate Forum <http://www.eccforum.org>
> www.toni-klemm.de | @toniklemm <http://twitter.com/toniklemm>
>
>
>
>
>
>
>
> _______________________________________________
> ncl-talk mailing list
> ncl-talk at ucar.edu
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20181219/777e5818/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: shapefile.000002.png
Type: image/png
Size: 204133 bytes
Desc: not available
URL: <http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20181219/777e5818/attachment.png>


More information about the ncl-talk mailing list