Re: [R-sig-Geo] shortestPath in a loop

2017-01-24 Thread marta azores
Hi guys, I'm still trying to solve my deal. How I can join the survey boat points using the shortestpath function, to avoid the land. It's important because I need an output "spatialLines"(boat surveys) to intersect with points( species points). I add several files : script and other layers of inf

Re: [R-sig-Geo] Help regarding Autoencoder

2017-01-24 Thread Roger Bivand
On Tue, 24 Jan 2017, Subir Paul wrote: Dear All, I was using "SAENET" package for autoencoding. I used the following code: h=SAENET.train(data[,1:200], n.nodes = c(100, 20), unit.type = ("logistic"), lambda = 0.001, beta = 0.0001, rho = 0.01, epsilon = 0.01, optim.method = c("BFGS"

[R-sig-Geo] Help regarding Autoencoder

2017-01-24 Thread Subir Paul
Dear All, I was using "SAENET" package for autoencoding. I used the following code: h=SAENET.train(data[,1:200], n.nodes = c(100, 20), unit.type = ("logistic"), lambda = 0.001, beta = 0.0001, rho = 0.01, epsilon = 0.01, optim.method = c("BFGS"), rel.tol=sqrt(.Machine$d

Re: [R-sig-Geo] Converting raster to a matrix

2017-01-24 Thread Ben Tupper
Hi, It doesn't seem to be noted in the documentation for raster::raster(), but when you create a RasterLayer from a RasterLayer, as in your > rast <- raster(image) step, the values are stripped from the resulting RasterLayer. Why don't you eliminate that step and retrieve the matrix from yo

Re: [R-sig-Geo] Converting raster to a matrix

2017-01-24 Thread Michael Sumner
What is dim(rast)? Try raster::readAll(rast) - what happens? On Tue, Jan 24, 2017, 19:26 John Wasige wrote: > ​Dear all, > Greetings! > > I want to convert a big raster (see attached) a matrix, however, I get the > error below from the script. Anybody with an Idea on what is going wrong in > my

[R-sig-Geo] Converting raster to a matrix

2017-01-24 Thread John Wasige
​Dear all, Greetings! I want to convert a big raster (see attached) a matrix, however, I get the error below from the script. Anybody with an Idea on what is going wrong in my script? ###Errors at the following point in the script​ > mat <- as.matrix(rast)Error in .local(x, ...) : 'x' has no val