Re: [R-sig-Geo] [R-sig-DB] [R] Connecting to PostgreSQL/PostGIS from R (rgdal?)

2007-06-02 Thread David James
Dirk, I agree that it would be worthwhile to re-visit what the DBI should provide, and I fully agree that R/S-Plus compatibility should not be a goal. Let me remind you that the DBI at the time it was defined more than 5 years ago was not meant to be a complete specification -- it identified m

Re: [R-sig-Geo] Spatial simulation

2007-06-02 Thread Virgilio Gomez-Rubio
Dear Kitty, What I usually do when I want to generate a spatially varying variable is to generate some points at random in the study area and then do a kernel smoothing on those points. The values of my variable at (x,y) are the values of the kernel smoothing at that point. Hope this helps. Virg

Re: [R-sig-Geo] Spatial simulation

2007-06-02 Thread Terry Griffin
I conducted similar simulations using invIrM in the spdep package. Dr. Anselin has a nice tutorial entitled Spatial Regression Analysis in R, A Workbook ( http://www.sal.uiuc.edu/stuff/stuff-sum/pdf/rex1.pdf ) (90 pp., 456K) at http://www.sal.uiuc.edu/stuff/stuff-sum/tutorials where I began to

[R-sig-Geo] Spatial simulation

2007-06-02 Thread Kitty Lee
Yes, let me be more specific. Say I have two variables, X and Y. I know that at the individual level, the relationship between them is: Y=a + bX+ error I try to run some simulation where X is spatially clustered. I can generate spatially clustered points, e.g. nsp.u2<-pcp.sim(25,40,.001, sp

Re: [R-sig-Geo] [R-sig-DB] [R] Connecting to PostgreSQL/PostGIS from R (rgdal?)

2007-06-02 Thread Tim Keitt
On 6/2/07, Prof Brian Ripley <[EMAIL PROTECTED]> wrote: > On Sat, 2 Jun 2007, Tim Keitt wrote: > > > On 6/2/07, Prof Brian Ripley <[EMAIL PROTECTED]> wrote: > >> On Sat, 2 Jun 2007, Tim Keitt wrote: > > [...] > > >> > Edzer's approach is one I've suggested on many occasions -- that we > >> > subcla

Re: [R-sig-Geo] [R-sig-DB] [R] Connecting to PostgreSQL/PostGIS from R (rgdal?)

2007-06-02 Thread Prof Brian Ripley
On Sat, 2 Jun 2007, Tim Keitt wrote: > On 6/2/07, Prof Brian Ripley <[EMAIL PROTECTED]> wrote: >> On Sat, 2 Jun 2007, Tim Keitt wrote: [...] >> > Edzer's approach is one I've suggested on many occasions -- that we >> > subclass the sp classes to act as a proxy to a PostGIS table. I first >> > de

Re: [R-sig-Geo] [R-sig-DB] [R] Connecting to PostgreSQL/PostGIS from R (rgdal?)

2007-06-02 Thread Dirk Eddelbuettel
Brian, On 2 June 2007 at 19:08, Prof Brian Ripley wrote: | There are quite a few 'db API' features in RODBC that are not in DBI. Random idea of the day: Would it be wortwhile to re-think what the DBI API should cover? These days, it may matter less to be R and S-Plus compatible [1] but e.g. t

Re: [R-sig-Geo] [R-sig-DB] [R] Connecting to PostgreSQL/PostGIS from R (rgdal?)

2007-06-02 Thread Tim Keitt
On 6/2/07, Prof Brian Ripley <[EMAIL PROTECTED]> wrote: > On Sat, 2 Jun 2007, Tim Keitt wrote: > > > My Rdbi (+Rdbi.PgSQL) package was written to be much simpler and > > easier to use than either DBI or RODBC. Unfortunately, I do not have > > time to maintain it, so I'm not sure what state it is in

Re: [R-sig-Geo] [R-sig-DB] [R] Connecting to PostgreSQL/PostGIS from R (rgdal?)

2007-06-02 Thread Prof Brian Ripley
On Sat, 2 Jun 2007, Tim Keitt wrote: > My Rdbi (+Rdbi.PgSQL) package was written to be much simpler and > easier to use than either DBI or RODBC. Unfortunately, I do not have > time to maintain it, so I'm not sure what state it is in. Either DBI > or RODBC should work fine for pushing tables back

Re: [R-sig-Geo] [R] Connecting to PostgreSQL/PostGIS from R (rgdal?)

2007-06-02 Thread Tim Keitt
My Rdbi (+Rdbi.PgSQL) package was written to be much simpler and easier to use than either DBI or RODBC. Unfortunately, I do not have time to maintain it, so I'm not sure what state it is in. Either DBI or RODBC should work fine for pushing tables back and forth. RODBC is probably the most up-to-da

Re: [R-sig-Geo] [R] Connecting to PostgreSQL/PostGIS from R (rgdal?)

2007-06-02 Thread Edzer J. Pebesma
Mike, my experience with linking R with PostGIS are documented here: http://wiki.intamap.org/index.php/PostGIS which I may have mentioned before on r-sig-geo. Indeed, as Tim confirms, besides the (r)gdal link, (R)ODBC is another working link for transferring table information. I doubt whether i

Re: [R-sig-Geo] Clipping a large image without reading in the entire image

2007-06-02 Thread Edzer J. Pebesma
Andrew Niccolai wrote: > Therefore, does anyone have any solutions for reading in an image >that would work in theory like the following: > >setwd(anypathway) >tif.image <- "VERY_LARGE_IMAGE.tif" >Bounded.tif <- GDAL.open(tif.image, bbox=c(UpL.X, LwR.X, UpL.Y, LwR.Y)) > >By the way, I am not set

Re: [R-sig-Geo] Clipping a large image without reading in the entire image

2007-06-02 Thread Roger Bivand
On Fri, 1 Jun 2007, Andrew Niccolai wrote: > Greetings Spatial R users/developers, > > I was curious as to whether or not it would be possible to describe a > bounding box for a large image so that what is read into R would be just the > contents of the image inside the bounding box. Conceptuall