Skip to content
Prev 4771 / 29559 Next

no boundaries between countries by using unionSpatialPolygons

On Wed, 7 Jan 2009, Hans-J?rg Bibiko wrote:

            
Excellent question - easy to reproduce!

Your ID has two unique values:
[1] (-67.1,-64.6] [-74.4,-71.9]
Levels: [-74.4,-71.9] (-71.9,-69.5] (-69.5,-67.1] (-67.1,-64.6]

with two country polygons:
[1] 2

so you get two output polygons. If you do:

ID2 <- rep("pe_bo", length(slot(pe_bo_data, "polygons")))
pe_bo <- unionSpatialPolygons(pe_bo_data, ID2)

gives one output polygon:
[1] 1

and no boundary.

Roger