finnts/man/ensemble_models.Rd

63 строки
1.8 KiB
Plaintext
Исходник Обычный вид История

% Generated by roxygen2: do not edit by hand
2022-04-01 06:14:10 +03:00
% Please edit documentation in R/finnts_0.2.0_ensemble_models.R
\name{ensemble_models}
\alias{ensemble_models}
\title{Ensemble Models}
\usage{
ensemble_models(
2022-09-15 20:57:03 +03:00
run_info,
parallel_processing = NULL,
num_cores = NULL,
seed = 123
)
}
\arguments{
2022-09-24 06:30:19 +03:00
\item{run_info}{run info using the 'set_run_info' function}
2022-03-20 05:23:40 +03:00
2022-09-24 06:30:19 +03:00
\item{parallel_processing}{Default of NULL runs no parallel processing and forecasts each individual time series
one after another. 'local_machine' leverages all cores on current machine Finn is running on. 'azure_batch'
runs time series in parallel on a remote compute cluster in Azure Batch.}
2022-03-20 05:23:40 +03:00
2022-09-24 06:30:19 +03:00
\item{num_cores}{Number of cores to run when parallel processing is set up. Used when running parallel computations
on local machine or within Azure. Default of NULL uses total amount of cores on machine minus one. Can't be greater
than number of cores on machine minus 1.}
2022-03-20 05:23:40 +03:00
2022-09-24 06:30:19 +03:00
\item{seed}{Set seed for random number generator. Numeric value.}
}
\value{
2022-09-24 06:30:19 +03:00
Ensemble model outputs are written to disk
}
\description{
Ensemble Models
}
2022-09-24 06:30:19 +03:00
\examples{
\donttest{
data_tbl <- timetk::m4_monthly \%>\%
dplyr::rename(Date = date) \%>\%
dplyr::mutate(id = as.character(id)) \%>\%
dplyr::filter(Date >= "2012-01-01",
Date <= "2015-06-01")
run_info <- set_run_info()
prep_data(run_info,
input_data = data_tbl,
combo_variables = c("id"),
target_variable = "value",
date_type = "month",
forecast_horizon = 3)
prep_models(run_info,
models_to_run = c("arima", "ets", "glmnet"),
num_hyperparameters = 2)
train_models(run_info,
run_global_models = TRUE,
run_local_models = TRUE,
combo_variables = c("id"))
ensemble_models(run_info)
}
}