dismo
dismo copied to clipboard
Unable to use specific test occurrence records with maxent()
Hello,
For the sake of reproducible results I have already randomly split my occurrence records into training and testing, and would like to input these records into dismo::maxent
. I have attempted to do this using the code below:
mod_args
[1] "linear=TRUE"
[2] "quadratic=TRUE"
[3] "hinge=TRUE"
[4] "product=TRUE"
[5] "threshold=TRUE"
[6] "betamultiplier=3"
[7] "randomtestpoints=40"
[8] "jackknife=TRUE"
[9] "responsecurves=TRUE"
[10] "testsamplesfile=C:/Users/Danielle/Downloads/presence_records_gridded_300.csv"
maxent_train <- dismo::maxent(env, # environmental variables (aka predictors)
occ_train, # training occurrence records
bgr, # background points, n = 10000
args = mod_args,
removeDuplicates = FALSE)
However when doing this I get the following error message:
Error in file(con, "r") : cannot open the connection
In addition: Warning message:
In file(con, "r") :
cannot open file 'C:\Users\Danielle\AppData\Local\Temp\RtmpcTd0O7/raster/maxent/1115481455/species.lambdas': No such file or directory
When I remove the argument testsamplesfiles=...
from mod_args, the function works as expected.
Is there a way to supply maxent with specific testing occurrence records?