Skip to contents

This function helps to correct the forecasts' biases based on ML (random forest) training on the previous time points.

Usage

debias.ML(pred.name, cov.names, dat.train, dat.pred, var.name, py.init)

Arguments

pred.name

character: the name for the predictive variable.

cov.names

character: the name for the covariates.

dat.train

data.frame: data frame containing associated covariates and predictive variable for ML training.

dat.pred

data.frame: data frame containing associated covariates for prediction.

var.name

character: variable name to be predicted.

py.init

R function: R function to initialize the python functions. Default is NULL. the default random forest will be used if `py.init` is NULL.

Value

list: the ML predicted residuals and other ML outputs.

Author

Dongchen Zhang