IDL - Extracting data from within boundary defined by shapefile [message #73795] |
Sat, 27 November 2010 04:04  |
katie
Messages: 3 Registered: November 2010
|
Junior Member |
|
|
Hello all,
I am using IDL 6.1, and was wondering if it's possible to extract data
(defined by lat and long gridpoints) from within a boundary defined by
a shapefile. For example, I have a contour map of global soil
moisture, but would only like to look at the data within the
Mississippi River Basin. I have the shapefile for this basin, and have
overplotted it onto the contour map so I can see the basin outline and
note that it is properly projected on top of my data, but I do not
know where to go from there.
Any advice would be great!
Thanks,
Katie
|
|
|
Re: IDL - Extracting data from within boundary defined by shapefile [message #73820 is a reply to message #73795] |
Wed, 01 December 2010 20:28  |
katie
Messages: 3 Registered: November 2010
|
Junior Member |
|
|
David -
"You actually have 64*128 points that you want to check,
so you have to make that many lats and lons:"
I actually thought about that after I wrote the message, but didn't
know how exactly to do it, so thanks for the code. And I did end up
needing to shift my longitudes around for the ContainsPoints to find
them, so thanks for that link as well. :-)
Paulo -
Noted about the loop, and fixed. Thanks for finding that and pointing
it out.
Things are now working a whole lot better for me. Thanks guys!
|
|
|