The goal of this package is to provide an improved version of WA-PLS by including the tolerances of taxa and the frequency of the sampled climate variable. This package also provides a way of leave-out cross-validation that removes both the test site and sites that are both geographically close and climatically close for each cycle, to avoid the risk of pseudo-replication.
You can install the released version of fxTWAPLS from CRAN with:
install.packages("fxTWAPLS")
And the development version from GitHub with:
install.packages("remotes")
::install_github("special-uor/fxTWAPLS", "dev") remotes
fxTWAPLS v0.0.2
install.packages("remotes")
::install_github("special-uor/fxTWAPLS@v0.0.2") remotes
The following functions can be executed in parallel:
To do so, include the cpus
parameter. For example:
# without fx
<- fxTWAPLS::cv.w(taxa,
cv_Tmin $Tmin,
modern_pollennPLS = 5,
::WAPLS.w,
fxTWAPLS::WAPLS.predict.w,
fxTWAPLScpus = 2)
Optionally, a progress bar can be displayed for long computations.
Just “pipe” the function call to fxTWAPLS::pb()
.
# without fx
`%>%` <- magrittr::`%>%`
<- fxTWAPLS::cv.w(taxa,
cv_Tmin $Tmin,
modern_pollennPLS = 5,
::WAPLS.w,
fxTWAPLS::WAPLS.predict.w,
fxTWAPLScpus = 2) %>%
::pb() fxTWAPLS
Alternatively, if you are not familiar with the “pipe” operator, you can run the following code:
# without fx
<- fxTWAPLS::pb(fxTWAPLS::cv.w(taxa,
cv_Tmin $Tmin,
modern_pollennPLS = 5,
::WAPLS.w,
fxTWAPLS::WAPLS.predict.w,
fxTWAPLScpus = 2))