[Qgis-developer] QGIS remote control API
Barry Rowlingson
b.rowlingson at lancaster.ac.uk
Tue Mar 14 10:51:23 PDT 2017
I'm doing some spatial analysis with R. I've read in a shapefile:
> data = shapefile("input.shp")
then I've done some analysis:
> data$stats = something(data)
Now I want to map it. I can use R's plot function, but that's not
interactive, hard to add background layers and style, no labelling,
cartography etc. I could use leaflet, but that requires JS code to get
anything custom. So I write a shapefile:
> shapefile(data, "output.shp")
Start QGIS, load the shapefile, realise all my column names have been
mashed to 12 characters (or whatever), style it. Go "huh" and think.
Back to R. Repeat.
With a QGIS remote control API I could do something like:
> addQgisLayer(data)
and *bang* there it is in Qgis. With data flow in that direction, Qgis
is a cartographic display for R's spatial data. But data flow could go
the other way - so that Qgis layers could be easily read back into R
spatial data.
In theory you could wrap the entire Python API to the remote control
API. At that point the use cases are almost like any Python QGIS use
cases, except expanded to any language or system that can send a web
request. R, Matlab, JS, perl, ruby.. even Python if you want to be
slightly perverse and can't run from the python interpreter.
Barry
On Tue, Mar 14, 2017 at 3:35 PM, Tom Chadwin <tom.chadwin at nnpa.org.uk> wrote:
> What are some example use cases?
>
> Tom
>
>
>
> -----
> Buy Pie Spy: Adventures in British pastry 2010-11 on Amazon
> --
> View this message in context: http://osgeo-org.1560.x6.nabble.com/QGIS-remote-control-API-tp5312091p5312279.html
> Sent from the QGIS - Developer mailing list archive at Nabble.com.
> _______________________________________________
> Qgis-developer mailing list
> Qgis-developer at lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
More information about the Qgis-developer
mailing list