Hi,
I am working with a SpatialPolygonsDataFrame of many islands. There are a
lot of polygons (islands) composing my SpatialPolygonsDataFrame.
I want to extract the elevation of each island.
I need to separate the different polygons (like dissolve function in
arcgis), to have the elevation of each island.
Do you have any idea how can I do that ?
I already read a lot of forum, and read the maptools package but I did not
find something useful for my problem.
Coordinates:
min max
x 40.32140 63.500179
y -25.60895 -3.711519
Is projected: FALSE
proj4string : [+proj=longlat +ellps=WGS84 +no_defs]
Data attributes:
NAME TYPE
Madagascar and the Indian Ocean Islands:1 hotspot_area:1
NAME_TYPE
Madagascar and the Indian Ocean Islands_hotspot_area:1
LEGEND
Madagascar and the Indian Ocean Islands:1 > class(hot)
[1] "SpatialPolygonsDataFrame"
attr(,"package")
[1] "sp"
Thanks a lot for your help,
C?line
--
View this message in context:
http://r.789695.n4.nabble.com/Dissolve-polygon-tp4637234.html
Sent from the R help mailing list archive at Nabble.com.
On Fri, Jul 20, 2012 at 4:51 PM, Celine <bellard.celine at gmail.com> wrote:> Hi, > > I am working with a SpatialPolygonsDataFrame of many islands. There are a > lot of polygons (islands) composing my SpatialPolygonsDataFrame. > I want to extract the elevation of each island.Is each island a row in your SPDF? Or is it just one row, with lots of island polygons? What does dim(hot) (assuming 'hot' is your SPDF) say?> I need to separate the different polygons (like dissolve function in > arcgis), to have the elevation of each island.If each island is a row, then its easy, if each island is a separate loop in a single row, a bit trickier. How are you going to get the elevation? Do you have a separate data source, such as a grid of elevations? Also, try hopping over to the R-sig-geo mailing list. For everything spatial. Barry blog: http://geospaced.blogspot.com/ web: http://www.maths.lancs.ac.uk/~rowlings web: http://www.rowlingson.com/ twitter: http://twitter.com/geospacedman pics: http://www.flickr.com/photos/spacedman