Re: [R-sig-Geo] tooltips or annotation

2015-06-14 Thread boB Rudis
You could always try using leaflet : http://rstudio-pubs-static.s3.amazonaws.com/57933_7b3caba2c24e4af686420c9f27437719.html On Sun, Jun 14, 2015 at 9:12 AM, Erich Subscriptions erich.s...@neuwirth.priv.at wrote: Is it possible to produce chorepeth maps with tooltips in svg? I found

Re: [R-sig-Geo] leaflet problem

2015-08-01 Thread boB Rudis
The documentation for addTiles has this: addTiles(map, urlTemplate = http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png;, attribution = NULL, layerId = NULL, group = NULL, options = tileOptions()) By default, when one does:

Re: [R-sig-Geo] From spatial points to spatial pictures

2015-08-05 Thread boB Rudis
Can you provide a (small) real set of data (with real values for x y)? On Wed, Aug 5, 2015 at 9:56 AM, Maurizio Marchi mauriziomarch...@gmail.com wrote: photosynthetic radiation ___ R-sig-Geo mailing list R-sig-Geo@r-project.org

Re: [R-sig-Geo] From spatial points to spatial pictures

2015-08-05 Thread boB Rudis
Maurizio provided his data set offline. The code + data + sample plots are in this gist: https://gist.github.com/hrbrmstr/e29cf9138e480db9e67d The data is just as he described it, so it's really just a matter of creating some polygons from the the points spline interpolation:

[R-sig-Geo] Positing a coord_proj for ggplot2

2015-07-24 Thread boB Rudis
Hey folks Having finally gotten tired of performing coordinate conversions to Winkel-Tripel (and other) projections prior to passing map data to ggplot2 (coord_map projection support is limited to what mapproject supports and that's pretty scant) I was toying with a coord_proj coordinate system

Re: [R-sig-Geo] readGDAL and unz

2015-07-21 Thread boB Rudis
You can just do: unzip(x.zip, x.tif) and it will only extract that single file out to the current working directory. readGDAL expects a filename vs a connection. On Tue, Jul 21, 2015 at 3:17 PM, Sarah Goslee sarah.gos...@gmail.com wrote: Hi folks, I'm stuck trying to read spatial data

Re: [R-sig-Geo] polygon neighbor matrix

2015-08-31 Thread boB Rudis
I second the `gTouches` suggestion. There's a ref here: http://stackoverflow.com/a/26499134/1457051 but the gist of it is (this user needed adjacent polygons in ghana): library(rgeos) library(rgdal) # using http://data.biogeo.ucdavis.edu/data/diva/adm/GHA_adm.zip ghana <- readOGR("GHA_adm",

Re: [R-sig-Geo] WKT coordinate system string (PRJ) to PROJ.4

2016-01-05 Thread boB Rudis
Tue, Jan 5, 2016 at 5:57 AM, boB Rudis <b...@rudis.net> wrote: > This may not be optimal as it uses an external service: > > prj_to_epsg <- function(prj) { > > require(sp) > require(httr) > require(jsonlite) > > res <- GET("http://prj2ep

Re: [R-sig-Geo] WKT coordinate system string (PRJ) to PROJ.4

2016-01-05 Thread boB Rudis
This may not be optimal as it uses an external service: prj_to_epsg <- function(prj) { require(sp) require(httr) require(jsonlite) res <- GET("http://prj2epsg.org/search.json;, query=list(exact=TRUE, error=TRUE,

Re: [R-sig-Geo] WKT coordinate system string (PRJ) to PROJ.4

2016-01-05 Thread boB Rudis
40], PARAMETER["false_northing",-10], UNIT["Meter",1]]' showP4(prj_1) ## [1] "+proj=tmerc +lat_0=49 +lon_0=-2 +k=0.9996012717 +x_0=40 +y_0=-10 +datum=OSGB36 +units=m +no_defs " On Tue, Jan 5, 2016 at 6:20 AM, boB Rudis <b...@rudi

Re: [R-sig-Geo] Mapping Singapore data

2016-01-14 Thread boB Rudis
This can get you started (if you're the ggplot2 sort of person). raster::getData will pull the data without a manual download. I'm not sure what you need admin-level-wise, so I went with Admin1. ggplot2::fortify takes the spatial data and makes it something ggplot2 can work with. It would normally

Re: [R-sig-Geo] Tearing of polygons using ggmap & readOGR

2016-01-31 Thread boB Rudis
Clip the state polygons with gIntersection. You cross-posted to StackOverflow & here so there's a complete answer there as it's more amenable to source code + commentary + images and will be around for quite a while despite what folks may opine about mailing lists. On Sun, Jan 31, 2016 at 8:03

Re: [R-sig-Geo] Merging regions in a map & plotting values

2016-01-19 Thread boB Rudis
(just noticed this) You should probably fix the ""South " & ""South & S.E" (there's a space missing in the former), too. On Tue, Jan 19, 2016 at 8:48 PM, boB Rudis <b...@rudis.net> wrote: > I think this might help you out a bit (it's probably worth

Re: [R-sig-Geo] Merging regions in a map & plotting values

2016-01-19 Thread boB Rudis
I think this might help you out a bit (it's probably worth taking the time to look it over as it removes much of the redundant code you had). library(sp) library(maptools) library(rgeos) library(rgdal) library(dplyr) library(ggplot2) library(ggthemes) library(ggalt) URL <-

Re: [R-sig-Geo] Merging regions in a map & plotting values

2016-01-20 Thread boB Rudis
information > such as % disease prevalence in every region, temperature, flock size etc > > Thanks advance > > Josh > > > On Wednesday, 20 January 2016, 1:49, boB Rudis <b...@rudis.net> wrote: > > > I think this might help you out a bit (it's probably worth taking t

Re: [R-sig-Geo] Merging regions in a map & plotting values

2016-01-22 Thread boB Rudis
ear to work now. However still >> stuck >> on the other bit on merging data with spatial object, ("regions") in this >> case to be able to plot the data points. I mainly want to plot information >> such as % disease prevalence in every region, temperature, flock siz

Re: [R-sig-Geo] How to plot Geohash on a Map using R

2016-04-14 Thread boB Rudis
Two months later and Oliver Keyes took a suggestion I gave him seriously and you now have a C++-backed super-fast geohashing package to do what you need: https://github.com/Ironholds/geohash/ On Mon, Feb 29, 2016 at 1:24 PM, Edzer Pebesma wrote: > Ravi, a student

Re: [R-sig-Geo] Address from Wikimapia

2016-05-17 Thread boB Rudis
Just be aware that their API limit is up to 100 requests in 5 minutes. On Tue, May 17, 2016 at 9:56 PM, Ista Zahn wrote: > Maybe. The API is documented at http://wikimapia.org/api. You can interact > with the API using (e.g.) the httr or curl packages in R. > > Best, > Ista >

Re: [R-sig-Geo] Links to Zika virus paper

2016-04-21 Thread boB Rudis
> > Cheers, > Roman > > On Thu, Apr 21, 2016 at 1:29 PM, boB Rudis <b...@rudis.net> wrote: >> >> Agreed it was great to see "Each of the 300 individual models was >> fitted using the gbm.step subroutine in the dismo package in the R >> stat

Re: [R-sig-Geo] Links to Zika virus paper

2016-04-21 Thread boB Rudis
Agreed it was great to see "Each of the 300 individual models was fitted using the gbm.step subroutine in the dismo package in the R statistical programming environment (Elith et al. 2008)" in there and also agreed that the following should have made it into the citations (assuming only

Re: [R-sig-Geo] Announcing the R Shapefile Contest

2016-07-14 Thread boB Rudis
IIRC at least the r-forge rgdal supports GDAL 2.0 which (I'm assuming) means it can read GeoPackage files. If that's true, then I'm sure Ari wldn't mind it being classified as a "shapefile". Barry: (this is in lieu of a google search on my part after work) do you have any links to some public

Re: [R-sig-Geo] Announcing the R Shapefile Contest

2016-07-14 Thread boB Rudis
t; > > > On Thu, Jul 14, 2016 at 7:16 PM +0200, "boB Rudis" <b...@rudis.net> wrote: > > IIRC at least the r-forge rgdal supports GDAL 2.0 which (I'm assuming) > means it can read GeoPackage files. If that's true, then I'm sure Ari > wldn't mind it being classifie

Re: [R-sig-Geo] Merge data by latitude and longitude

2016-10-16 Thread Bob Rudis
When your cross-post on StackOverflow is answered (or is answered here) were you planning on cross-posting the answer as well? On Sun, Oct 16, 2016 at 9:32 AM, Miluji Sb wrote: > Dear all, > > I have two dataframe 1 by latitude and longitude but they always do not > match. Is