identying shapefile polygons containing long-lat points
I believer the overlay() function in the sp package will do this. -Don
At 7:33 PM -0400 7/22/08, jatwood at montana.edu wrote:
Good Afternoon I searched the archives but could not find the answer to my question. I have shapefiles for various geographic regions such as states, counties, zipcode areas, townships, etc. I also have long-lat coordinates for 12000 plus weather stations. I am able to use maptools to plot the maps and am able to plot the points on the polygon maps with appropriate text. However, I also need to be able to identify which shapefile polygon each weather station (or pobbibly other long-lat points) lies within. Does any package have a function similar to the "maps" packages' "map.where" function that would work with more general shapefile polygons? I am new to this list so please excuse me if this question has been previously addressed. I will appreciate any help or suggestions. -------------------------------------------------------------------- mail2web.com ? Enhanced email for the mobile individual based on Microsoft? Exchange - http://link.mail2web.com/Personal/EnhancedEmail
_______________________________________________ R-sig-Geo mailing list R-sig-Geo at stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo
--------------------------------- Don MacQueen Lawrence Livermore National Laboratory Livermore, CA, USA 925-423-1062 macq at llnl.gov