Re: [R-sig-Geo] maptools/SpatialPolygons2PolySet produces ascending instead of descending POS numbers for polygons with holes

2014-08-06 Thread Roger Bivand
On Wed, 6 Aug 2014, Daniel Rodolphe Schlaepfer wrote: Unfortunately, your suggestion to consider plotting order doesn’t work in general and not in my case; for instance, if I need my underlaying map to show filled polygons: plot(polySP, density=10, angle=45, pbg="white", axes=TRUE) map(add=TR

Re: [R-sig-Geo] spatio-temporal simultaneous autoregression model

2014-08-06 Thread Corey Sparks
Yes, you can choose a zero inflated poisson or negative binomial likelihood. - Corey Sparks Associate professor Department of Demography The University of Texas at San Antonio 501 West Cesar E Chavez Blvd San Antonio TX 78207 coreysparks.weebly.com 210 458 3166 Latitud

Re: [R-sig-Geo] spatio-temporal simultaneous autoregression model

2014-08-06 Thread stevenhuyi
Thanks Corey. Yeah, what you mentioned is indeed the problem. However, does INLA can deal with the problem of many "zero" values if a count data model is assumed? >You need to be careful with the incidence data if the Gaussian model isn't appropriate, I assume that many >counties have very low p

Re: [R-sig-Geo] spatio-temporal simultaneous autoregression model

2014-08-06 Thread Corey Sparks
You need to be careful with the incidence data if the Gaussian model isn't appropriate, I assume that many counties have very low prevalence, so a count data model may be more appropriate. I would check out INLA, it will do Bayesian models over space and time, there are some tutorials/examples here

Re: [R-sig-Geo] maptools/SpatialPolygons2PolySet produces ascending instead of descending POS numbers for polygons with holes

2014-08-06 Thread Daniel Rodolphe Schlaepfer
Unfortunately, your suggestion to consider plotting order doesn’t work in general and not in my case; for instance, if I need my underlaying map to show filled polygons: plot(polySP, density=10, angle=45, pbg="white", axes=TRUE) map(add=TRUE, fill=TRUE, col=rainbow(n=5)) -the hatched polygon is

Re: [R-sig-Geo] maptools/SpatialPolygons2PolySet produces ascending instead of descending POS numbers for polygons with holes

2014-08-06 Thread Roger Bivand
On Wed, 6 Aug 2014, Daniel Rodolphe Schlaepfer wrote: Thank you for the suggestion. Unfortunately, this does not work for my application: I plot the polygon on top of other another plot where I need the holes of the polygon to be transparent. For instance, I don’t want the African countries in

Re: [R-sig-Geo] maptools/SpatialPolygons2PolySet produces ascending instead of descending POS numbers for polygons with holes

2014-08-06 Thread Daniel Rodolphe Schlaepfer
Thank you for the suggestion. Unfortunately, this does not work for my application: I plot the polygon on top of other another plot where I need the holes of the polygon to be transparent. For instance, I don’t want the African countries in the following examples to be covered by white: library

Re: [R-sig-Geo] Spatial partitioning of direct, indirect and total impacts (2)

2014-08-06 Thread Roger Bivand
On Wed, 6 Aug 2014, Janka VANSCHOENWINKEL wrote: Dear list members, I am sorry that I am going to repeat my question. I do not want to insist, but since I sent it right before the weekend, the timing was probably not so good and I thought it would be good to give it a second chance. I am tryin

Re: [R-sig-Geo] spTransform() error : "load package rgdal for spTransform methods"

2014-08-06 Thread Michael Sumner
It's an ill-targeted error message. But, you aren't supposed to reproject a SpatialGrid, both because sp/rgdal cannot do that without low-level usage and since it's really an empty container (that can be a SpatialGridDataFrame) Use raster::projectRaster after conversion to raster objects (or proba

Re: [R-sig-Geo] spTransform() error : "load package rgdal for spTransform methods"

2014-08-06 Thread Roger Bivand
On Wed, 6 Aug 2014, Remi Genevest wrote: Hi, I am facing a recurrent problem associated with spTransform() function from rgdal package. While I try to change the CRS of a SpatialGrid, I get the following error : Error in spTransform(grd, CRS("+init=epsg:3857")) : load package rgdal for spTrans

[R-sig-Geo] Spatial partitioning of direct, indirect and total impacts (2)

2014-08-06 Thread Janka VANSCHOENWINKEL
Dear list members, I am sorry that I am going to repeat my question. I do not want to insist, but since I sent it right before the weekend, the timing was probably not so good and I thought it would be good to give it a second chance. I am trying to reproduce table 2.1 (p. 41) of LeSage and Pace

Re: [R-sig-Geo] maptools/SpatialPolygons2PolySet produces ascending instead of descending POS numbers for polygons with holes

2014-08-06 Thread Roger Bivand
On Wed, 6 Aug 2014, Daniel Rodolphe Schlaepfer wrote: Hello all, I try to convert a sp SpatialPolygons object with a hole to a PBS PolySet object - my ultimate goal is to plot the polygon with hatching considering the hole. The problem is not that you need a PolySet representation, but that

[R-sig-Geo] spTransform() error : "load package rgdal for spTransform methods"

2014-08-06 Thread Remi Genevest
Hi, I am facing a recurrent problem associated with spTransform() function from rgdal package. While I try to change the CRS of a SpatialGrid, I get the following error : Error in spTransform(grd, CRS("+init=epsg:3857")) : load package rgdal for spTransform methods Does anybody know how to so

[R-sig-Geo] Auto-Re: R-sig-Geo Digest, Vol 132, Issue 6

2014-08-06 Thread ����ϲ
收到,谢谢! ___ R-sig-Geo mailing list R-sig-Geo@r-project.org https://stat.ethz.ch/mailman/listinfo/r-sig-geo

[R-sig-Geo] algorithm to compare a building in two different datasets

2014-08-06 Thread Mervyn Ó' Lúing
Hi all, I was wondering if an algorithm exists which can be used compare buildings in an OSM dataset with another (benchmark) dataset and tell whether the building in OSM is on the right side of the road. An idea would be to: 1) get the address a building, 2) from the address get the road the bu

Re: [R-sig-Geo] spatio-temporal simultaneous autoregression model

2014-08-06 Thread stevenhuyi
Thanks, Roger. I will try. It's my fault to mistakenly write the spautolm function as a package. what do mean by saying "if your space-time data are balanced". My data is multiple years of prevalence data of schistosomiasis at the county level, combined with data of environmental determinants.

[R-sig-Geo] maptools/SpatialPolygons2PolySet produces ascending instead of descending POS numbers for polygons with holes

2014-08-06 Thread Daniel Rodolphe Schlaepfer
Hello all, I try to convert a sp SpatialPolygons object with a hole to a PBS PolySet object - my ultimate goal is to plot the polygon with hatching considering the hole. My problem is that maptools/SpatialPolygons2PolySet only produces PolySet objects with increasing POS even for polygons with

Re: [R-sig-Geo] spatio-temporal simultaneous autoregression model

2014-08-06 Thread Roger Bivand
On Wed, 6 Aug 2014, stevenhuyi wrote: Hi everyone, It seems that there is no specific R package to implement the space-time SAR model. I happend to find an article entitled "Spatio-temporal regression models for deforestation in the Brazilian Amazon" (literature information: STDM 2011, The Inte

[R-sig-Geo] spatio-temporal simultaneous autoregression model

2014-08-06 Thread stevenhuyi
Hi everyone, It seems that there is no specific R package to implement the space-time SAR model. I happend to find an article entitled "Spatio-temporal regression models for deforestation in the Brazilian Amazon" (literature information: STDM 2011, The International Symposium on Spatial-Temporal A