[R-sig-Geo] time-series

2013-04-22 Thread lily li
Hi All, I have a question about time-series in R. For example, I have a variable with several years' data (continuous years), while each year has 12 months. When use aggregate function, it says that it calculates the annual mean value of this variable. But I think it's problematic. What does aggr

Re: [R-sig-Geo] Memory limits in R with shapefiles

2013-04-22 Thread Michael Sumner
gdalwarp is not for shapefiles Dominic: at the command line with GDAL installed you can use *ogr2ogr* to subset and otherwise manipulate shapefiles and that may be your best route. http://www.gdal.org/ogr_utilities.html But, what is the size of the component files? Sometimes it's the .shp that i

Re: [R-sig-Geo] moran.plot: sum or mean?

2013-04-22 Thread Roger Bivand
On Mon, 22 Apr 2013, Robert J. Hijmans wrote: I am using package spdep. I have a listw object (lw) and a vector of values (y) and I want to make a Moran scatterplot (with unadjusted values): library(spdep) m <- matrix(c(0, 1, 1, 0, 0, 0, 1, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 1, 0,

[R-sig-Geo] moran.plot: sum or mean?

2013-04-22 Thread Robert J. Hijmans
I am using package spdep. I have a listw object (lw) and a vector of values (y) and I want to make a Moran scatterplot (with unadjusted values): library(spdep) m <- matrix(c(0, 1, 1, 0, 0, 0, 1, 0, 1, 0, 1, 1, 1, 1, 0, 1, 0, 1, 0, 0, 1, 0, 0, 1, 0, 1, 0, 0, 0, 1, 0, 1, 1, 1, 1, 0), ncol=6) lw <- m

Re: [R-sig-Geo] subsetting a WKT Multilinestring

2013-04-22 Thread Roger Bivand
On Mon, 22 Apr 2013, Philip A. Viton wrote: Consider: library(rgeos) mls<-readWKT("MULTILINESTRING((3 4, 10 50, 20 25),(30 30, 70 50, 24 55) ,(30 12, 50 5, 65 7))") length(mls) #[1] 1 mls1<-readWKT("GEOMETRYCOLLECTION(LINESTRING(3 4, 10 50, 20 25), LINESTRING(30 30, 70 50, 24 5

Re: [R-sig-Geo] subsetting a WKT Multilinestring

2013-04-22 Thread Edzer Pebesma
On 04/22/2013 07:04 PM, Philip A. Viton wrote: > Consider: > > library(rgeos) > mls<-readWKT("MULTILINESTRING((3 4, 10 50, 20 25),(30 30, 70 50, 24 55) > ,(30 12, 50 5, 65 7))") > > mls is, as expected, a SpatialLines object, and > plotting it shows that indeed it has three individ

[R-sig-Geo] subsetting a WKT Multilinestring

2013-04-22 Thread Philip A. Viton
Consider: library(rgeos) mls<-readWKT("MULTILINESTRING((3 4, 10 50, 20 25),(30 30, 70 50, 24 55) ,(30 12, 50 5, 65 7))") mls is, as expected, a SpatialLines object, and plotting it shows that indeed it has three individual lines. My question is: is there some way to subset this obje

[R-sig-Geo] Fwd: wrong colour class for sub-map

2013-04-22 Thread Alessandra Carioli
Dear bloggers, I have been working with maps lately, and I am quite new to the environment. What I want to do is obtain a main map of Spain mainland (spain.main) and one selection for the canary islands (spain.canarias) that are made by selection 51 and 52 and be coloured according to certain cat

Re: [R-sig-Geo] Memory limits in R with shapefiles

2013-04-22 Thread Thiago V. dos Santos
What kind of operation do you need to perform in the shapefiles? Depending on it, one solution could be calling gdal commands from within R, by using system(). For example: system('gdalwarp argument1 argument2 argument3 argument4')   Greetings, -- Thiago V. dos Santos PhD student Land and Atmosp

[R-sig-Geo] Memory limits in R with shapefiles

2013-04-22 Thread Dominic Roye
Hello everyone, I have a problem with reading a shape of 300 MB in R. My RAM limits are 8 GB. So, i can´t work with this shape, because it needs more than 8GB. Have anybody an idea how to handle this kind of cases? Best regards, Dominic [[alternative HTML version deleted]]

[R-sig-Geo] How to translate coordinates from cylindrical to a Lambert Azimuthal Equal Area Projection

2013-04-22 Thread Ivailo
Dear Listmembers, I have a 40 000 x 40 000 GeoTIFF file that I need to crop to an area of interest (perhaps about 1000 x 1000 pixels, 25 x 25 m grid). The file seems to be in the Lambert Azimuthal Equal Area Projection (coord. ref. : +proj=laea +lat_0=52 +lon_0=10 +x_0=4321000 +y_0=321 +ellps=

Re: [R-sig-Geo] rgdal: libgdal requirements too restrictive

2013-04-22 Thread Roger Bivand
On Sun, 21 Apr 2013, Kirill Müller wrote: On 04/21/2013 08:31 PM, Roger Bivand wrote: You could ask there what resources they would need to offer less antiquated packages for stable, which is your specific problem - testing and unstable are not up to date, but are not bad. The only practical s