Nothing
## ----include = FALSE----------------------------------------------------------
knitr::opts_chunk$set(
warning = FALSE,
collapse = TRUE,
comment = "#>",
fig.width = 8,
fig.height = 6
)
## ----message = FALSE----------------------------------------------------------
library(patterncausality)
data(climate_indices)
## -----------------------------------------------------------------------------
X <- climate_indices$PNA
Y <- climate_indices$NAO
## -----------------------------------------------------------------------------
run_cv_test <- function(n_cores) {
start_time <- Sys.time()
result <- pcCrossValidation(
X = X,
Y = Y,
numberset = c(100, 200, 300, 400, 500),
E = 3,
tau = 2,
metric = "euclidean",
h = 1,
weighted = FALSE,
random = TRUE,
bootstrap = 100,
n_cores = n_cores,
verbose = TRUE
)
end_time <- Sys.time()
return(difftime(end_time, start_time, units = "secs"))
}
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.