Skip to content
Prev 23583 / 29559 Next

Exporting Multipolygon geojson with rgdal::writeOGR

Thanks very much Roger.

I've replicated this on my work machine (Windows) and on my Mac at home.

KML and GML are both affected. ESRI shapefile works fine and, though
I'm not very familiar with the format, 'MapInfo File' works too
(loading the file in qgis shows a multipart polygon with no geometry
errors).

sessionInfo() for my Windows machine (using rgdal 1.0-7 with included
gdal drivers):

R version 3.2.2 (2015-08-14)
Platform: i386-w64-mingw32/i386 (32-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1

locale:
[1] LC_COLLATE=English_Canada.1252  LC_CTYPE=English_Canada.1252
LC_MONETARY=English_Canada.1252
[4] LC_NUMERIC=C                    LC_TIME=English_Canada.1252

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
[1] rgdal_1.0-7 sp_1.2-0

loaded via a namespace (and not attached):
[1] tools_3.2.2     grid_3.2.2      lattice_0.20-33


I'll send the details for my Mac environment this evening.

I'll dig into the source code as soon as I can - C is a completely
foreign language to me, so I can't promise anything fast!

Thanks again,
Andy
On Thu, Oct 22, 2015 at 12:27 AM, Roger Bivand <Roger.Bivand at nhh.no> wrote: