[R-sig-Geo] rpostgis announcement

Mathieu Basille basille.web at ase-research.org
Tue Aug 30 17:25:20 CEST 2016


Thank you Edzer for the feedback!

We have been watching sfr, and I really look forward to its completion!

Now to answer your question, the choice of using WKT (and WKB from package
'wkb' when possible on write, for better performance) was initially driven
by the fact that Windows binaries for rgdal are not compiled with
PostgreSQL/PostGIS support, which is a huge problem. Having to deal with a
class of students (mostly using Windows) trying to make it work was just a
big mess! :)

In addition, on read, it also allows to subquery the data with any clause
(WHERE, ORDER BY, LIMIT, etc.), which was still not possible with rgdal
last time I checked (admittedly a few months ago).

All in all, rgeos::read/writeWKT (and additionally wkb::read/writeWKB)
gives us the flexibility that we were looking for. Note that we didn't
check how efficient it was in comparison with rgdal (in terms of performance).

As a side note, having EWKB/EWKT standardized and usable in R (for instance
through sfr) would be a real plus! In our case, dealing with projection
information (SRID) was really not straightforward...

Best,
Mathieu.


Le 29/08/2016 16:19, Edzer Pebesma a écrit :
> Nice development!
> 
> In the simple features for R project, https://github.com/edzer/sfr , I
> have been writing direct (E)WKB <--> R conversions, and support reading
> tables with geometry from PostGIS, using sf::st_read_pg(db, table). I
> was thinking about how to do the writing when your package came!
> 
> The advantage of the sf package, over sp, is that it supports (will
> support) all 17 geometry types for 4 dimensions (XY, XYZ, XYM, XYZM).
> 
> In order to try to gain momentum for this, could you provide a few
> arguments and/or use cases for which this approach is more useful than
> readOGR/writeOGR in rgdal?
> 
> Best regards,
> 
> On 29/08/16 16:48, David Bucklin wrote:
>> Dear r-sig-geo list members,
>>
>> We'd like to announce the initial CRAN release of 'rpostgis' (v1.0.0),
>> which facilitates transfer between PostGIS "Geometry" objects (stored in
>> PostgreSQL databases) and R spatial objects. The package also contains a
>> variety of convenience functions which are supplemental to the excellent
>> 'RPostgreSQL' package for interfacing with a PostgreSQL/PostGIS database.
>>
>> To install the package:
>>
>> install.packages("rpostgis")
>>
>> The package main development area can be found on GitHub; any bugs, issues,
>> or feature requests can be submitted through the "issues" page there:
>>
>> https://github.com/mablab/rpostgis
> 
> I did!
> 
>>
>> David
>>
>> 	[[alternative HTML version deleted]]
>>
>> _______________________________________________
>> R-sig-Geo mailing list
>> R-sig-Geo at r-project.org
>> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
>>
> 
> 
> 
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo
> 

-- 

Mathieu Basille

basille at ufl.edu | http://ase-research.org/basille
+1 954-577-6314 | University of Florida FLREC

  « Le tout est de tout dire, et je manque de mots
  Et je manque de temps, et je manque d'audace. »
  — Paul Éluard

This message is signed to guarantee its authenticity.
For a true private correspondence, use my public key
to encrypt your messages:

  http://mathieu.basille.net/pub.asc

Learn more: http://mzl.la/1BsOGiZ

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20160830/5ebd5f6d/attachment.bin>


More information about the R-sig-Geo mailing list