[R-sig-Geo] Problem using mahasuhab

Ned Horning horning at amnh.org
Fri Nov 20 04:18:42 CET 2009


Hi - I was wondering if anyone out there can help with my effort to 
create habitat suitability maps using mahasuhab from the adehabitat 
package or another package if there is a better option. I would like to 
compare the resulting maps with some software a colleague is working on.

When I try to import an ascii grid using the import.asc method I get the 
following error:
--
Error in if ((yll[[1]][1] == "yllcenter") | (xll[[1]][1] == 
"YLLCENTER")) corny <- FALSE :
  missing value where TRUE/FALSE needed
In addition: Warning messages:
1: In import.asc(filename, type = "numeric") : NAs introduced by coercion
2: In import.asc(filename, type = "numeric") : NAs introduced by coercion
--

I am able to read the test ascii grid file that comes with the package 
just fine. I can also read my file using stack() from the raster package 
but I don't know how to convert that RasterStack to an asc or kasc 
object which seems to be necessary to run mahasuhab.

Any pointers?

Ned



More information about the R-sig-Geo mailing list