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

2008-10-31 Thread Edward Tomlinson
Hi all, I am not sure as to which list this best fits (Grass or R-sig-geo). I am trying to reclass a raster map (ndvi) into 5 different zones using the fisher method, ultimatley i am trying to reclass as natural breaks. The point of this exercise is for precision agriculture. I want to determine

Re: [R-sig-Geo] gstat::variogram - distance calculation isincorrect; kriging on sphere

2008-10-31 Thread Hengl, T.
Hi Greg, Just a small remark: it would not be a special treatment because I am anyway 80% of my time located in Amsterdam ;) Edzer, thanx for fixing this problem. I did run kriging on LatLon projected data a lot actually. LatLon coordinates are especially attractive because you can then dire

Re: [R-sig-Geo] Extracting data/value

2008-10-31 Thread Alexander Brenning
Hi Mikael, you can use some of the functions in the RSAGA package to extract values from a file (grid/shapefile) or data.frame and attach them to a data.frame with point locations. If I may assume that 'indata' is an grid, try any of pick.from.ascii.grid pick.from.saga.grid rsaga.add.g

Re: [R-sig-Geo] Add Grid Values to Points

2008-10-31 Thread Alexander Brenning
Hi Tim, the most recent release of RSAGA has a wrapper function for this module that is called rsaga.add.grid.values.to.points; try this: rsaga.add.grid.values.to.points("test", c("slope", "aspect"), "add_grid", method = "nearest.neighbour", env = myenv) (Note that the wrapper function us

[R-sig-Geo] Add Grid Values to Points

2008-10-31 Thread Tim Häring
Hello to everybody, I´m trying to use the SAGA tool "Add Grid Values to Points" in R using the RSAGA package ("shapes_grid", 0) but there is an error message I can`t figure out.: > rsaga.geoprocessor("shapes_grid",0, list(SHAPES="test.shp", > GRIDS=list("slope.sgrd", "aspect.sgrd"), RESULT="a

[R-sig-Geo] Extracting data/value

2008-10-31 Thread Mikael Carlsson
Dear readers, I have one file look like ew;ns;cu;zn 1234567;7654321;23.4;13.7 name indata load with read.table command another file look like 2;cu;zn name parmlst also load with read.table I want to do as follows cu.v <- as.vector(cu) zn.v<- as.vector(zn) but using a for loop, like for (i in

Re: [R-sig-Geo] Error in fit.variogram in gstatVariogram recalled from file

2008-10-31 Thread Paul Hiemstra
Hi Cora, A mucht better way of storing R-objects in files is through the use of the save() command. The load() command is the equivalent to reload the file. Example in code: vmodel = vgm(10, "Exp", 300, 4.5) save(vmodel, file = "vmodel.rda") # reloading the file load("vmodel.rda") see ?save

Re: [R-sig-Geo] gstat::variogram - distance calculation is incorrect; kriging on sphere

2008-10-31 Thread Greg Lee
No sign of sp 0.9-27 at this end (Melbourne, Australia) yet. Interesting that it should take so long. I temporarily reset my repository to access the updates. Croatia already has sp 0.9-28, along with gstat 0.9-53. (Does Tomislav receive special treatment?) Your example now works perfectly. Thank

Re: [R-sig-Geo] gstat::variogram - distance calculation is incorrect; kriging on sphere

2008-10-31 Thread Edzer Pebesma
That's right; my fault that I sent the email and updated the sp package on CRAN almost at the same time. The new sp (0.9-27 would suffice) should now have propagated to your mirror, simply update your sp package again and it should work. Let me know if it doesn't. -- Edzer Greg Lee wrote: Hel