[R-sig-Geo] Subscripting by coordinates

2007-06-15 Thread Agustin Lobo
an stratified sampling: test3.stsamp - spsample(test3, n = 10, stratified) Now, I would like to get the values of test3 at positions [EMAIL PROTECTED], but [EMAIL PROTECTED] does not work. How should I do it? Thanks Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera

[R-sig-Geo] spsample and NA

2007-06-20 Thread Agustin Lobo
of X Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster ___ R-sig-Geo mailing

Re: [R-sig-Geo] ODP: spsample and NA

2007-06-21 Thread Agustin Lobo
, Helleveien 30, N-5045 Bergen, [EMAIL PROTECTED] Od: [EMAIL PROTECTED] w imieniu Agustin Lobo Wysłano: Śr 20.06.2007 10:11 Do: R-sig-Geo@stat.math.ethz.ch Temat: [R-sig-Geo] spsample and NA It is often the case, at least with raster (grid) objects, that you

[R-sig-Geo] distmap

2007-06-22 Thread Agustin Lobo
via readOGR. distmap.owin requires type polygonal and readOGR yields class 'SpatialPolygonsDataFrame' Is there any way to cast or convert from 'SpatialPolygonsDataFrame' to polygonal or an alternative function to calculate the distances to the boundaries of the polygons? Thanks Agus -- Dr. Agustin

Re: [R-sig-Geo] distmap

2007-06-25 Thread Agustin Lobo
... .. ..$ y: num [1:10] 2.23 2.70 2.71 2.63 2.50 ... - attr(*, class)= chr owin but how can I do it? Also, I'm so confused with so many spatial objects, is there a guide? Agus Roger Bivand escribió: On Fri, 22 Jun 2007, Agustin Lobo wrote: Dear sig-geos, I have to calculate a distmap

Re: [R-sig-Geo] ODP: ODP: spsample and NA

2007-06-25 Thread Agustin Lobo
to avoid NAs. I am not sure how to proceed without access to a copz of zour data to see whz spsample is including the NA cells. Roger --- Roger Bivand, NHH, Helleveien 30, N-5045 Bergen, [EMAIL PROTECTED] Od: Agustin Lobo w imieniu Agustin Lobo Wys³ano: Cz

Re: [R-sig-Geo] distmap

2007-06-26 Thread Agustin Lobo
) I can send you limit2.rda, is that ok? Agus Roger Bivand escribió: On Mon, 25 Jun 2007, Edzer J. Pebesma wrote: Roger Bivand wrote: On Mon, 25 Jun 2007, Agustin Lobo wrote: I've tried (among other things): limit1 - read.shape(limit_PNSN2000.shp) Shapefile type: Polygon, (5

Re: [R-sig-Geo] ODP: ODP: spsample and NA

2007-06-26 Thread Agustin Lobo
: additional to the X = as(X, SpatialPixelsDataFrame) etc. there's a helper function that toggles between them; try: fullgrid(X) = TRUE class(X) fullgrid(X) = FALSE class(X) -- Edzer Agustin Lobo wrote: I understand, but how do I convert between one type and the other? I've tried: x

[R-sig-Geo] vector to raster

2007-07-05 Thread Agustin Lobo
Dear sig-geos, is there any way of converting from vector (imported with rgdal from a shp) to raster within R? Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL

Re: [R-sig-Geo] vector to raster

2007-07-05 Thread Agustin Lobo
you write pts as a geotif using rgdal? Thanks! Agus Edzer J. Pebesma escribió: Agustin Lobo wrote: Dear sig-geos, is there any way of converting from vector (imported with rgdal from a shp) to raster within R? Thanks! Agus Yes, using the classes and methods in sp -- you'd first

[R-sig-Geo] [Fwd: SpatialPolygons: Problems with cross overs?]

2007-07-05 Thread Agustin Lobo
,],],zcol=OBJECTID) spplot(refG[crossov[4,],],zcol=OBJECTID) etc. (BTW, why the following code does not plot anything?: for (i in 1:nrow(crossov)){ print(crossov[i,]) spplot(refG[crossov[i,],],zcol=OBJECTID) readline() } Thanks for any help! Agus -- Dr. Agustin Lobo Institut de

[R-sig-Geo] problems with writeGDAL (rgdal)

2007-07-09 Thread Agustin Lobo
? Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster ___ R-sig-Geo mailing

[R-sig-Geo] [Fwd: Re: spatstat objects and sp: distmap result to sp]

2007-07-09 Thread Agustin Lobo
) Regards -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster ___ R-sig-Geo mailing list R

[R-sig-Geo] Distmap: the way I could do it

2007-07-10 Thread Agustin Lobo
: Datum is lost GFODISTLOG - refG25 [EMAIL PROTECTED] - [EMAIL PROTECTED] writeGDAL(GFODISTLOG, GFODISTLOG.tif, drivername = GTiff, type = Float32, mvFlag = NA, options=NULL) Hope this helps somebody else. Please let me know if you think of a better way. Agus -- Dr. Agustin Lobo Institut de

[R-sig-Geo] readOGR and nonASCII character

2007-07-11 Thread Agustin Lobo
Hi list, Is there any way to get readOGR() to correctly read non-ascii character strings from the dbf file? I've checked and my dbf file correctly displays names with accents, but once read into R accents are substituted by wrong symbols. Agus -- Dr. Agustin Lobo Institut de Ciencies de la

Re: [R-sig-Geo] map algebra with ascii grid

2007-07-15 Thread Agustin Lobo
. Think what would happen if band1 was categorical or logical to see why doing arithmetic directly isn't such a good idea. Hope this helps, Roger Thank you for any suggestions. Best wishes, Michal -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis

[R-sig-Geo] Distmap Inconsistency?

2007-07-22 Thread Agustin Lobo
30.44687 dif[dif0] [1] 6.638003 30.446868 29.122913 27.613710 25.879159 23.867316 21.509986 18.716394 [9] 15.364044 11.285587 6.250307 Is this a problem with distmap or am I misunderstanding something? I can send the rda file upon request if anybody can help. Agus -- Dr. Agustin Lobo

Re: [R-sig-Geo] readOGR and nonASCII character

2007-07-23 Thread Agustin Lobo
datasets methods base other attached packages: spatstat mgcv shapefiles maptoolsforeign rgdal sp 1.11-7 1.3-23 0.6 0.6-13 0.8-20 0.5-13 0.9-14 Agus Roger Bivand escribió: On Wed, 11 Jul 2007, Agustin Lobo wrote: Hi list, Is there any way to get

Re: [R-sig-Geo] readOGR and nonASCII character

2007-07-24 Thread Agustin Lobo
patience Agus Roger Bivand escribió: On Mon, 23 Jul 2007, Agustin Lobo wrote: Roger, read.shapefile() and read.dbf() yields weird symbols for non-ascii characters in the input file also. Exporting to csv and reading in with read.csv(filename,sep=;) works fine (yes, it's odd, excel puts

[R-sig-Geo] distmap for polygons imported from shapefiles

2007-08-13 Thread Agustin Lobo
. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster ___ R-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch

Re: [R-sig-Geo] polygon buffers?

2007-09-02 Thread Agustin Lobo
/listinfo/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster ___ R-sig-Geo mailing

Re: [R-sig-Geo] Barry Rowlingson's Arlat on FOSS4G 2007

2007-10-01 Thread Agustin Lobo
list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo ___ R-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume

Re: [R-sig-Geo] Barry Rowlingson's Arlat on FOSS4G 2007

2007-10-01 Thread Agustin Lobo
list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo ___ R-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume

Re: [R-sig-Geo] add random fluctuation x and y coordinates

2007-10-17 Thread Agustin Lobo
-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster

[R-sig-Geo] v.stats.rast for category raster or vector cross statistics

2007-10-22 Thread Agustin Lobo
samll cell size (Br is large) Any easier way through R? -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster

[R-sig-Geo] SaTScan: (geo)graphical visualization in R?

2007-10-23 Thread Agustin Lobo
Has anyone written R scripts to visualize SaTScan output or anything that could be useful as an starting point? (just to avoid unnecessary work!) SaTScan: http://www.satscan.org/ Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028

Re: [R-sig-Geo] SaTScan: (geo)graphical visualization in R?

2007-10-23 Thread Agustin Lobo
about that. Hope this helps. Virgilio On Tue, 2007-10-23 at 12:58 +0200, Agustin Lobo wrote: Has anyone written R scripts to visualize SaTScan output or anything that could be useful as an starting point? (just to avoid unnecessary work!) SaTScan: http://www.satscan.org/ Agus

[R-sig-Geo] overlay polygons (from shp) and raster (from geotif)

2007-10-23 Thread Agustin Lobo
are outside the raster and I'm not interested on those). Also, cells are much larger then the width of the polygons (I can send a jpg with an example). So it's clear I'm doing something wrong... any advice? Thanks -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole

Re: [R-sig-Geo] overlay polygons (from shp) and raster (from geotif)

2007-10-24 Thread Agustin Lobo
to the polygons. How could I convert the SpatialGridDataFrame into an SpatialPolygons object? Then I would need to convert to PBSmapping Polysets... BTW, there is no vector intersection in grass either, am I wrong? Thanks, Agus Roger Bivand escribió: On Tue, 23 Oct 2007, Agustin Lobo wrote: Thanks

[R-sig-Geo] identify for SpatialGridDataFrame objects?

2007-10-25 Thread Agustin Lobo
(delme.cl.im) I get: Error in as.double(y) : cannot coerce to vector Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster

[R-sig-Geo] Problem closing gdal file

2007-10-26 Thread Agustin Lobo
of type character Is there a better way to solve this problem than just exiting R? Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es

[R-sig-Geo] Boundary of SpatialGridDataFrame ?

2007-10-26 Thread Agustin Lobo
on the SpatialGridDataFrame object to extract raster values from each polygon and compare. Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster

Re: [R-sig-Geo] Subsetting SpatialPolygonsDataFrame and empty ID slots

2007-10-30 Thread Agustin Lobo
] 1 2 3 pols_Lupuna - pols[sites_Lupuna,] seems to provide a correctly subset of the original pols object (Lupuna 1, Lupuna 2, Lupuna 3) Am I wrong? I feel quite insecure on this. Agus Roger Bivand escribió: On Mon, 29 Oct 2007, Agustin Lobo wrote: Dear list, I have imported a shp file

Re: [R-sig-Geo] Divide a polygon by a line?

2007-11-02 Thread Agustin Lobo
[EMAIL PROTECTED] wrote: On Tue, 30 Oct 2007, Agustin Lobo wrote: Is it possible to divide a polygon by a line into 2 polygons? No, in general. All computational geometry ends up in having to deal with the type of polygon. A convex polygon is one thing, and can be divided into two parts

[R-sig-Geo] convUL: wrong for Southern hemisphere

2007-11-03 Thread Agustin Lobo
. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster ___ R-sig-Geo mailing list R-sig-Geo

Re: [R-sig-Geo] convUL: wrong for Southern hemisphere

2007-11-03 Thread Agustin Lobo
for convUL(), though, just to mention it) Agus Roger Bivand escribió: On Sat, 3 Nov 2007, Agustin Lobo wrote: Dear list, For negative latitudes (Southern hemisphere), convUL yields negative UTM coordinates as for Northern hemisphere, instead of positive UTMY coordinates for the South. I

[R-sig-Geo] spRbind() limited to 2 objects?

2007-11-04 Thread Agustin Lobo
, pols.ferns3) : unused argument(s) (S4 object of class SpatialPolygonsDataFrame) class(spRbind(spRbind(pols.ferns1,pols.ferns2),pols.ferns3)) [1] SpatialPolygonsDataFrame attr(,package) [1] sp Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s

[R-sig-Geo] Qgis and R ?

2007-12-03 Thread Agustin Lobo
Hi! Does anyone has experience at displaying spatial R objects with QGis (perhaps using the python console + Rpy or RSpython)? I'm thinking on starting some testing and would like to know about previous experiences. Thanks -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC

[R-sig-Geo] spTransform: datum syntax?

2007-12-06 Thread Agustin Lobo
with ellps= The doc refers to the proj.4 doc, but cannot find any list of datums there, including the pdf docs of proj.4 Does anyone know where I could find a list of supported datums in proj.4 and their correct names for the +datum= argument? Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies

Re: [R-sig-Geo] spTransform: datum syntax?

2007-12-07 Thread Agustin Lobo
. This is the upper left corner of the upper left cell, the upper right corner of the upper right cell, etc. Roger Bivand escribió: On Thu, 6 Dec 2007, Agustin Lobo wrote: Dear list, I have to transform the datum of an spatial object. First, I create the object with: pressp

Re: [R-sig-Geo] FYI: Merging GIS and statistics --- RSAGA

2008-01-30 Thread Agustin Lobo
be solved very easily if the next version of rgdal would support SAGA format. Tom Hengl http://spatial-analyst.net ___ R-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo -- Dr. Agustin Lobo

Re: [R-sig-Geo] shape of circles

2008-02-23 Thread Agustin Lobo
: Agustin Lobo wrote: Hi! I have to create a shp of circular polygons out of a file with x,y coordinates and radii. I've found that disc() from package GRID makes an owin object for each circle, but then how can I convert to sp (from there to shp using writeOGR)? To generate n points

Re: [R-sig-Geo] spplot with two rasters

2008-03-12 Thread Agustin Lobo
for context, while the second one is one with interesting z-values. The second raster is masked and thus does not cover the entire region. Thanks, Dylan -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34

Re: [R-sig-Geo] spplot with two rasters

2008-03-13 Thread Agustin Lobo
would be great. Agus -- Edzer Agustin Lobo wrote: Well, the problem is that R does not have a real geographical display. While things can be done going back and forth from R to GIS, this procedure soon becomes very inconvenient. It's ok for learning and teaching, but not for real

[R-sig-Geo] Test of independency in a contingency table for spatial variables

2008-04-02 Thread Agustin Lobo
is to randomize the values of the descriptors among the points and use a Monte Carlo approach. Is there any other way? Thanks! -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED

[R-sig-Geo] extracting polygons

2008-04-08 Thread Agustin Lobo
PROTECTED], owin) Error in as([EMAIL PROTECTED], owin) : no method or default for coercing Polygons to owin which is the proper way of selecting each polygon from within the SpatialPolygonsDataFrame object? Thanks! Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC

Re: [R-sig-Geo] extracting polygons

2008-04-08 Thread Agustin Lobo
: class([EMAIL PROTECTED]) [1] Polygons attr(,package) [1] sp why don't I have SpatialPolygons? Than Agus Agustin Lobo escribió: Dear list, I want to distribute a set of N circles according to a random distribution within a set of polygons (N circles within each polygon). I have

[R-sig-Geo] intersection of objects SpatialPolygonsDataFrame

2008-04-09 Thread Agustin Lobo
in the data frame of the map, so I do not know the habitat for each polygon within each circle. Any way to relate the new polygons to the data frame of the map? Or should I use an entirely different apporach in R? Or should I export x to a GIS and do this operation there? Thanks! Agus -- Dr. Agustin

Re: [R-sig-Geo] intersection of objects SpatialPolygonsDataFrame

2008-04-09 Thread Agustin Lobo
- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Agustin Lobo Sent: Wednesday, April 09, 2008 9:48 AM To: r-sig-geo@stat.math.ethz.ch Subject: [R-sig-Geo] intersection of objects SpatialPolygonsDataFrame Dear list, I have two objects of class SpatialPolygonsDataFrame and I

Re: [R-sig-Geo] extracting polygons

2008-04-10 Thread Agustin Lobo
: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Agustin Lobo Sent: Tuesday, April 08, 2008 12:56 PM Cc: r-sig-geo@stat.math.ethz.ch Subject: Re: [R-sig-Geo] extracting polygons I think that (at least part of) my problem comes from being confused about Polygons and SpatialPolygons

[R-sig-Geo] readOGR and proj4 string

2008-04-10 Thread Agustin Lobo
..@ plotOrder : int [1:1555] 148 143 792 740 209 335 895 619 1127 1160 ... ..@ bbox : num [1:2, 1:2] 412000 4584000 466000 4624000 .. ..- attr(*, dimnames)=List of 2 ..@ proj4string:Formal class 'CRS' [package sp] with 1 slots [EMAIL PROTECTED] CRS arguments: NA Agus -- Dr. Agustin

Re: [R-sig-Geo] readOGR and proj4 string

2008-04-10 Thread Agustin Lobo
: [412000, 466000] Y : [4584000, 4624000] Attributes Projection: UTM Zone : 31 Extra columns : Agus Roger Bivand escribió: On Thu, 10 Apr 2008, Roger Bivand wrote: On Thu, 10 Apr 2008, Agustin Lobo wrote: The manual page of readOGR states

[R-sig-Geo] PolySet2SpatialPolygons: ring not closed

2008-04-10 Thread Agustin Lobo
? plotMap(a) seems correct. Thanks Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster

Re: [R-sig-Geo] readOGR and proj4 string

2008-04-10 Thread Agustin Lobo
data.frame. Agus Roger Bivand escribió: On Thu, 10 Apr 2008, Agustin Lobo wrote: Thanks, This is what I'm doing: absUTMpolysHABS2 - readOGR(C:/ALOBO/Lidia,layer=test_TNT) t1 - CRS(paste(+proj=utm +zone=31 +ellps=intl,+towgs84=-87.0,-98.0,-121.0,0.0,0.0,0.0,0.0)) proj4string

Re: [R-sig-Geo] Qgis-Rmanage and geographic display of spatial objects

2008-05-14 Thread Agustin Lobo
on developing an igeoplots package! Agus Carson Agustin Lobo wrote: Thanks Carson, just knowing that this is an R console is enough. Now, after making a simple plot(), I'm just dreaming: if we could display sp objects directly, not only avoiding the intermediate shp file but being able of plotting

[R-sig-Geo] [Openspace] Re: Qgis-Rmanage and geographic display of spatialobjects

2008-05-14 Thread Agustin Lobo
on developing an igeoplots package! Agus Carson Agustin Lobo wrote: Thanks Carson, just knowing that this is an R console is enough. Now, after making a simple plot(), I'm just dreaming: if we could display sp objects directly, not only avoiding the intermediate shp file but being able of plotting

Re: [R-sig-Geo] projecting Lat and Long to 2D

2008-05-14 Thread Agustin Lobo
much in advance and i hope you are having a pleasant day. Harry ___ R-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole

Re: [R-sig-Geo] Dear Friends,

2008-05-23 Thread Agustin Lobo
___ R-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028

Re: [R-sig-Geo] clustering multi band images

2008-06-12 Thread Agustin Lobo
/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster ___ R-sig-Geo mailing list R

Re: [R-sig-Geo] clustering multi band images

2008-06-12 Thread Agustin Lobo
some of the points raised and in case I will come back with more clear ideas and questions. Thank you very much to everybody for the support. Laura 2008/6/12 Agustin Lobo [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]: If your images are large (and images typically are large because

Re: [R-sig-Geo] clustering multi band images

2008-06-12 Thread Agustin Lobo
of the points raised and in case I will come back with more clear ideas and questions. Thank you very much to everybody for the support. Laura 2008/6/12 Agustin Lobo [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]: If your images are large (and images typically are large because pixel size

Re: [R-sig-Geo] clustering multi band images

2008-06-12 Thread Agustin Lobo
Laura Poggio escribió: .../... 2008/6/12 Agustin Lobo [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]: May I just ask you if you have easily available an example of code to transform the image in a multivariate table pixels x bands? This would be helpful to avoid many trial and errors

Re: [R-sig-Geo] Load R sp vector layers in QGIS

2008-06-19 Thread Agustin Lobo
@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http://www.ija.csic.es/gt/obster

Re: [R-sig-Geo] Load R sp vector layers in QGIS

2008-06-19 Thread Agustin Lobo
-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: [EMAIL PROTECTED] http

[R-sig-Geo] Guide to plotting R spatial objects

2008-06-24 Thread Agustin Lobo
Hi! Is there a guide for plotting R spatial objects, best dealing with all (at least several) of the different spatial packages (sp, PBSmapping, maptools etc)? Thanks -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34

Re: [R-sig-Geo] rbind and spRbind

2008-07-27 Thread Agustin Lobo
are acceptable. Roger Hope this helps. Danlin Agustin Lobo wrote: I'm a bit confused with the following: I have a SPDF object ika1v4 dim([EMAIL PROTECTED]) [1] 693 23 dim(ika1v4geo) [1] 693 23 Then I do an rbind: a - rbind(ika1v4geo,ika1v4geo) dim(a) [1] 1386 23 dim([EMAIL

Re: [R-sig-Geo] reading tiff with jump?

2008-08-05 Thread Agustin Lobo
)) Regards, Agus Ashton Shortridge wrote: On Tuesday 05 August 2008, Roger Bivand wrote: On Tue, 5 Aug 2008, Agustin Lobo wrote: Hi! is it possible to read a tiff file with readGDAL but just keeping one pixel every p columns and q lines? That is, a systematic sampling at reading. This is good to save

[R-sig-Geo] Newbie question: Reclassifying raster (ndvi) using fisher method

2008-11-01 Thread Agustin Lobo
=ndvi.reclass rules=rules created in text doc title=title I hope this all makes sense. Thank you for your time and reading through my problem. If you have any suggestions i sure would be greatful. Kind regards, Ed -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole

[R-sig-Geo] numeric fields imported as factors by readOGR()

2008-12-05 Thread Agustin Lobo
I often get some numeric fields (i.e, AREA in this case) imported as factors by readOGR() from shp files. WHy could it be? I've reviewed the field in the dbf file and do not see any non-numeric value. Thanks Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole

Re: [R-sig-Geo] numeric fields imported as factors by readOGR()

2008-12-06 Thread Agustin Lobo
reports Integer, Real, or String, this should be respected, so I'd be interested in seeing a case. Roger -James On Fri, Dec 5, 2008 at 10:29 AM, Agustin Lobo [EMAIL PROTECTED] wrote: I often get some numeric fields (i.e, AREA in this case) imported as factors by readOGR() from shp files. WHy

Re: [R-sig-Geo] Material for asdar book

2009-01-02 Thread Agustin Lobo
message to the list just assuming that many subscribers would share the same interest, I appologize if this was actually inappropriate). Agus Roger Bivand wrote: On Fri, 2 Jan 2009, Agustin Lobo wrote: Hi! It would be helpful if the material (source, datasets...) of the asdar book could be made

[R-sig-Geo] EPIMAP format

2009-01-11 Thread Agustin Lobo
Hi! I have a bunch of files in *.MAP and *.REC formats. I've seen that I can import *.REC into R, but what about the *.MAP files? Is there any way to import those to R or a GIS program and then export to another format? Thanks Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume

[R-sig-Geo] Passing a parameter from R to r.mapcalc ?

2009-01-20 Thread Agustin Lobo
the shell through system, something like for (k in mistat[,1]){ system(set k = @1) system(r.mapcalc 'mancha = if(manchas.clmp==$k,1,0)') but do not get thru, (perhaps I'm mixing my memories of the csh and the Bourne shell...) any help? Agus -- Dr. Agustin Lobo Institut de

[R-sig-Geo] error rgdal library if used from within Grass plugin (Windows)

2009-02-09 Thread Agustin Lobo
(...) : GDAL Error 1: Can't load requested DLL: C:\OSGeo4W\bin\gdalplugins\gdal_ECW_JP2ECW.dll 126: Não foi possível encontrar o módulo especificado. Error : .onLoad failed in 'loadNamespace' for 'rgdal' Erro: package 'rgdal' could not be loaded Any help appreciated. Agus -- Dr. Agustin Lobo

[R-sig-Geo] Merging data frame for SpPolDF

2009-03-19 Thread Agustin Lobo
Hi! I often have to add more information to the data slot of a SpPolDF imported from a shp file. I do it in this way, don't like it too much and would like feed-back on a better way- #Import shp MMAMBmuni - readOGR(C:/Pruebas/DUNS/MMAMBmuni, layer=MMAMBmuni) #Extract the DF MMAMBmuniDFori -

Re: [R-sig-Geo] Merging data frame for SpPolDF

2009-03-19 Thread Agustin Lobo
Agustin Lobo wrote: Hi! I often have to add more information to the data slot of a SpPolDF imported from a shp file. I do it in this way, don't like it too much and would like feed-back on a better way- #Import shp MMAMBmuni - readOGR(C:/Pruebas/DUNS/MMAMBmuni, layer=MMAMBmuni) #Extract

Re: [R-sig-Geo] Extract coordinates from SpatialPolygonsDataFrame

2009-03-20 Thread Agustin Lobo
Hadley, It would be great if you could put your code in the wiki http://wiki.r-project.org/rwiki/doku.php?id=tips:spatial-data I think that David Hugh-Jones has contributed a lot to this site and he might advice on the best way of doing it (David: sorry if I'm wrong on this) Agus hadley

Re: [R-sig-Geo] delete shapefile in the directory

2009-03-20 Thread Agustin Lobo
system() lets you run any command on your OS Agus gianni lavaredo wrote: Hi all is there a code to delete shapefie in a directory? thanks Gianni [[alternative HTML version deleted]] ___ R-sig-Geo mailing list R-sig-Geo@stat.math.ethz.ch

[R-sig-Geo] readOGR and writeOGR: encoding?

2009-03-21 Thread Agustin Lobo
Hi! Is there any way to read the dbf of shp files that contain non-ascii characters? I've tried with encoding=UTF-8 or latin3 as for scan, but this argument does not exist for readOGR (or writeOGR) Agus ___ R-sig-Geo mailing list

Re: [R-sig-Geo] readOGR and writeOGR: encoding?

2009-03-21 Thread Agustin Lobo
Thanks! The problem is that only UTF-8 and latin1 area available , but for cases in which encoding of the dbf is different (i.e. IBM850 or Western Europe (DOS/OS2-850/International as recognized by OpenOffice in the case I'm dealing with now) I can read in QGIS and write with QGIS as UTF8 or

Re: [R-sig-Geo] Running analysis on DEMs using GRASS (from R?)

2009-03-25 Thread Agustin Lobo
Tomislav, This would be part of an R script using grass: brachspread - function(itmax=1,a=-1) { #Do the next once per session #attach(/media/mifat32/Rutils/utiles.rda) #Execute grass command: import tiff file into grass #Data: #manchas (importado de ) #noocup (importado de no_ocupable1.tif,

Re: [R-sig-Geo] Running analysis on DEMs using GRASS (from R?)

2009-03-25 Thread Agustin Lobo
user). I am just a beginner with GRASS, so it could be that things are much simpler than they seem (it could also be that they are also much more complicated). Many thanks, Tom Hengl http://home.medewerker.uva.nl/t.hengl/ -Original Message- From: Agustin Lobo [mailto:alobolis

Re: [R-sig-Geo] FW: Factor Analysis using R and grass

2009-03-26 Thread Agustin Lobo
Note that there has recently been a lot of traffic on this issue, visit http://grass.osgeo.org/wiki/Principal_Component_Analysis i.pca has given trouble since many years ago, the consensus was rather using m.eigensystem and r.mapcalc instead. It seems that the fact is the i.pca is equivalent to

Re: [R-sig-Geo] Factor Analysis using R and grass

2009-03-26 Thread Agustin Lobo
Brian, PCA does not care about raster or vector. All you need is a table of individuals x variables. Whether you get that from a vector or a raster does not matter at all. Instead, you must be careful with what your data mean. In particular, you mention centroids. If those are centroids of

[R-sig-Geo] Problem with sourceforge repository

2009-04-22 Thread Agustin Lobo
Hi! I'm doing as stated in http://r-spatial.sourceforge.net/ but get: rSpatial - http://r-spatial.sourceforge.net/R; install.packages(spgrass6, repos=rSpatial) Warning in install.packages(spgrass6, repos = rSpatial) : argument 'lib' is missing: using '/usr/local/lib/R/site-library' Warning

[R-sig-Geo] paste( / ) and paste( /' ) for grass command

2009-04-22 Thread Agustin Lobo
I wish to write using paste(), but paste(\,Hola,\,sep=) [1] \Hola\ while the same approach works with '' paste(\',Hola,\',sep=) [1] 'Hola' why this difference? how could I do it to get Hola ? I need this to write this string in R: v.extract codigo_Montseny07_clump out=extract11917

Re: [R-sig-Geo] paste( / ) and paste( /' ) for grass command

2009-04-22 Thread Agustin Lobo
will mean move to the next line in the console. Best, Jaime -R On Wed, 22 Apr 2009 10:31:55 +0200, Agustin Lobo alobolis...@gmail.com wrote: I wish to write using paste(), but paste(\,Hola,\,sep=) [1] \Hola\ while the same approach works with '' paste(\',Hola,\',sep=) [1] 'Hola

Re: [R-sig-Geo] [GRASS-stats] R-sig-Geo nabble forum request

2009-04-28 Thread Agustin Lobo
Great! The URL is http://n2.nabble.com/R-sig-geo-f2731867.html but it's readonly (I think), we cannot post from there, Posting would be the real advantage of using Nabble. Note that anything posted from Nabble goes through the list, Nabble is just a front end, users have to be subscribed to the

[R-sig-Geo] readRAST6 problem

2009-04-28 Thread Agustin Lobo
Hi! I'm getting this message at reading a grass raster file: rastdum - readRAST6(nomdum,cat=F) raster map/current region mismatch detected in components: colsrows origin.northing origin.easting TRUETRUE FALSETRUE set plugin=TRUE

[R-sig-Geo] spplot: no boundary lines for polygons

2009-05-05 Thread Agustin Lobo
Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email: agustin.l...@ija.csic.es http://www.ija.csic.es/gt/obster begin:vcard fn:Agustin Lobo n:Lobo;Agustin org:Institut de Ciencies de

[R-sig-Geo] readRAST6: too many open files

2009-05-05 Thread Agustin Lobo
. Is this a bug? I remember having a similar problem with writeGDAL() on a win machine a long ago, but that problem was fixed. Thanks Agus -- Dr. Agustin Lobo Institut de Ciencies de la Terra Jaume Almera (CSIC) LLuis Sole Sabaris s/n 08028 Barcelona Spain Tel. 34 934095410 Fax. 34 934110012 email

Re: [R-sig-Geo] readRAST6: too many open files

2009-05-05 Thread Agustin Lobo
versions, will retry and let you know Agus Roger Bivand wrote: On Tue, 5 May 2009, Agustin Lobo wrote: We're using rastdum - readRAST6(nomdum,cat=F,ignore.stderr = T) (on a ubuntu 8.10 machine and R 2.9) within a for() loop of hundreds of iterations. At some point (ca. 199) we get an error Too

Re: [R-sig-Geo] readRAST6: too many open files

2009-05-05 Thread Agustin Lobo
Roger, After upgrading, the test works with plugin=F, while plugin=T produces the same result. Also, ignore.stderr=T yields: ERROR 6: SetColorTable() only supported for Byte or UInt16 bands in TIFF format. WARNING: Input raster map constains cells with NULL-value (no-data). The

Re: [R-sig-Geo] readRAST6: too many open files

2009-05-06 Thread Agustin Lobo
spgrass6, rgdal and sp packages. Thanks a lot Agus Roger Bivand wrote: On Tue, 5 May 2009, Roger Bivand wrote: On Tue, 5 May 2009, Agustin Lobo wrote: Roger, After upgrading, the test works with plugin=F, while plugin=T produces the same result. I find this too on Fedora 10, plugin=TRUE fails

Re: [R-sig-Geo] [R-sig-Debian] [Fwd: Re: ubuntu problem with 'r-cran-robustbase' [FWD Agustin Lobo]]

2009-05-12 Thread Agustin Lobo
Michael: I do have the backports activated. This is the entry in my sources.list: deb http://archive.ubuntu.com/ubuntu/ hardy-backports restricted main multiverse universe deb-src http://archive.ubuntu.com/ubuntu/ hardy-backports restricted main multiverse universe And this is the output to

Re: [R-sig-Geo] [R-sig-Debian] [Fwd: Re: ubuntu problem with 'r-cran-robustbase' [FWD Agustin Lobo]]

2009-05-12 Thread Agustin Lobo
if everything was removed and installed back again? Is there any reason to think that installing R from sources is going to solve the problem? Thanks Agus Agustin Lobo wrote: Michael: I do have the backports activated. This is the entry in my sources.list: deb http://archive.ubuntu.com/ubuntu/ hardy

[R-sig-Geo] raster package

2009-05-18 Thread Agustin Lobo
I have to reclassify a large ( 8000x8000 pixels) geotif raster. I normally would do it through grass (or saga) but would like to try the raster package in R. The problem is that I'm a bit confused on how to do it. My understanding of the package is that it provides a way to operate in the rasters

Re: [R-sig-Geo] raster package

2009-05-20 Thread Agustin Lobo
to... That is exactly what is intended with reclass(). Something like this : r - raster('mytiffile.tif') m - matrix(0,1000,1, 1000, Inf, NA, ncol=2) rc - reclass(r, m, ...) Robert On Tue, May 19, 2009 at 1:36 AM, Agustin Lobo alobolis...@gmail.com wrote: I have to reclassify a large

[R-sig-Geo] coordinates

2009-06-19 Thread Agustin Lobo
Hi! When using coordinates(VEGPROimas20090409punts) - c(xc,yc) where VEGPROimas20090409punts is a dataframe and xc, yc column variables in the dataframe, xc and yc are deleted from the @data table of the resultinf spdf. I mean: VEGPROimas20090409punts[1,] site image xc

[R-sig-Geo] col,row coordinates from utmx,utmy coordinates

2009-06-19 Thread Agustin Lobo
Hi! Given a jpg + jpgw files I would like to get the col,row coordinates of the jpg file that correspond to a set of projected utmx, utmy coordinates, best not having to import the jpg file into R because of its size. Does this exist within R (in raster package or any other)? Or should I use

  1   2   3   >