[R-sig-Geo] A Qgis Map Graphics Device for R

Barry Rowlingson b.rowlingson at lancaster.ac.uk
Thu Aug 18 15:09:19 CEST 2016


On Thu, Aug 18, 2016 at 1:17 PM, Manuel Spínola <mspinola10 at gmail.com> wrote:
> Dear Barry,
>
> How I install the package?

 With difficulty...

 First you probably need to be running Linux and have Qgis 2.14 or
higher installed.

 Install the rPython package into R - install.packages("rPython") may
work, or may need you to install some system packages for your
operating system.

 Install the devtools package into R.

 Clone the gitlab repository.You might even want to fork it since I'm
working on the master branch and I break stuff all the time. I'll try
and work in a development branch and try and keep the master branch
fairly clean now:

 git clone git at gitlab.com:b-rowlingson/pqgisr.git
or
 git clone https://gitlab.com/b-rowlingson/pqgisr.git

  It doesn't work as an installed package yet (because I don't like
writing docs for code I'm only 10% certain is going to survive very
long), so use devtools to load it:

  devtools::load_all("./pqgisr")  # or wherever you cloned it to.

  then (if you have the rgdal package)

  init_qgis()
  add_ogr_layer(system.file("vectors/scot_BNG.shp",package="rgdal"))
  qgis

might pop up a map canvas with some scottish regions. Or crash R, or
give a warning about things not being found on your system...

 Successes and failure reports (with error messages, system
configuration, current phase of the moon etc) to the gitlab issue
tracker please!



More information about the R-sig-Geo mailing list