ecospat.CCV.createDataSplitTable | R Documentation |
Creates a DataSplitTable with calibration and evaluation data either for cross-validation or repeated split sampling at the community level (i.e., across all species).
ecospat.CCV.createDataSplitTable(NbRunEval,
DataSplit,
validation.method,
NbSites,
sp.data=NULL,
minNbPresences=NULL,
minNbAbsences=NULL,
maxNbTry=1000)
NbRunEval |
number of cross-validation or split sample runs |
DataSplit |
proportion (%) of sites used for model calibration |
validation.method |
the type of |
NbSites |
number of total sites available. Is ignored if sp.data is provided. |
sp.data |
a data.frame where the rows are sites and the columns are species (values 1,0) |
minNbPresences |
the desired minimum number of Presences required in each run |
minNbAbsences |
the desired minimum number of Absences required in each run |
maxNbTry |
number of random tries allowed to create a fitting DataSplitTable |
If a sp.data
data.frame with species presences and absences is provided the function tries to create a DataSplitTable
which ensures that the maximum possible number of species can be modelled (according to the specified minimum presences and absences.)
DataSplitTable |
a matrix with |
Daniel Scherrer <daniel.j.a.scherrer@gmail.com>
ecospat.CCV.modeling
#Creating a DataSplitTable for 200 sites, 25 runs with an
#80/20 calibration/evaluation cross-validation
DataSplitTable <- ecospat.CCV.createDataSplitTable(NbSites = 200,
NbRunEval=25,
DataSplit=80,
validation.method='cross-validation')
#Loading species occurence data and remove empty communities
testData <- ecospat.testData[,c(24,34,43,45,48,53,55:58,60:63,65:66,68:71)]
sp.data <- testData[which(rowSums(testData)>0), sort(colnames(testData))]
#Creating a DataSplitTable based on species data directly
DataSplitTable <- ecospat.CCV.createDataSplitTable(NbRunEval = 20,
DataSplit = 70,
validation.method = "cross-validation",
NbSites = NULL,
sp.data = sp.data,
minNbPresence = 15,
minNbAbsences = 15,
maxNbTry = 250)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.