Description Usage Arguments Value Author(s)
This function return a logical vector specifing which elements should be used for training or testing the dataset. It allow to specify several replicates, and then the output will be a matrix with as many columns as replicates have been specified. It also allow to change the proportion of training data which is 0.7 by default.
1 | trainSplit(m, nRep=1, perc=0.7, seed=NULL)
|
m |
Matrix. Community matrix that will be splitted in training and testing datasets. |
nRep |
Value. The number of replicates that will be run. Then the same number of random vector will be created and returned in a matrix. |
perc |
Value. Value in the range of 0 to 1 indicating the proportion of points to be used in training. |
seed |
Value. This value is used as initial seed for the first replicate, the next replicates will increase this seed by adding the number of the replicate. |
Matrix. The output is a matrix with one column for each replicate indicated (nRep). The number of rows in the matrix correspond with the number of sites in the community matrix (m).
Diego Nieto Lugilde
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.