if (FALSE) {
envs <- envs_userEnvs(rasPath = list.files(system.file("extdata/wc",
package = "wallace"),
pattern = ".tif$", full.names = TRUE),
rasName = list.files(system.file("extdata/wc",
package = "wallace"),
pattern = ".tif$", full.names = FALSE))
# extent of transfer
longitude <- c(-71.58400, -78.81300, -79.34034, -69.83331,
-66.47149, -66.71319, -71.11931)
latitude <- c(13.18379, 7.52315, 0.93105,
-1.70167, 0.98391, 6.09208, 12.74980)
selCoords <- matrix(c(longitude, latitude), byrow = FALSE, ncol = 2)
polyExt <-
sp::SpatialPolygons(list(sp::Polygons(list(sp::Polygon(selCoords)),
ID = 1)))
# load model
m <- readRDS(system.file("extdata/model.RDS",
package = "wallace"))
modXfer <- xfer_area(evalOut = m, curModel = 1, envs,
outputType = 'cloglog', alg = 'maxent.jar',
clamp = TRUE, xfExt = polyExt)
}
Run the code above in your browser using DataLab