workflow: Executing a time series prediction process

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/tspred.r

Description

workflow is a generic function for executing the steps of a particular data workflow. The function invokes particular methods which depend on the class of the first argument.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
workflow(obj, ...)

## S3 method for class 'tspred'
workflow(
  obj,
  data = NULL,
  prep_test = FALSE,
  onestep = obj$one_step,
  eval_fitness = TRUE,
  seed = 1234,
  ...
)

Arguments

obj

An object of class tspred defining a particular time series prediction process.

...

Ignored

data

See subset.tspred

prep_test

See preprocess.tspred

onestep

See predict.tspred

eval_fitness

See evaluate.tspred

seed

See set.seed

Details

The function workflow.tspred executes a time series prediction process defined by a tspred object. It is a wrapper for the methods subset preprocess, train, predict, postprocess, and evaluate, which are called in this order. The artifacts generated by the execution of the time series prediction process are introduced in the structure of the tspred class object in obj.

Value

An object of class tspred with updated structure containing all artifacts generated by the execution of the time series prediction process.

Author(s)

Rebecca Pontes Salles

See Also

[tspred()] for defining a particular time series prediction process.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
data(CATS)

#Obtaining objects of the processing class
proc1 <- subsetting(test_len=20)
proc2 <- BoxCoxT(lambda=NULL)
proc3 <- WT(level=1, filter="bl14")

#Obtaining objects of the modeling class
modl1 <- ARIMA()

#Obtaining objects of the evaluating class
eval1 <- MSE_eval()

#Defining a time series prediction process
tspred_1 <- tspred(subsetting=proc1,
                   processing=list(BCT=proc2,
                                   WT=proc3),
                   modeling=modl1,
                   evaluating=list(MSE=eval1)
)
summary(tspred_1)

tspred_1 <- workflow(tspred_1,data=CATS[3],onestep=TRUE)

TSPred documentation built on Jan. 21, 2021, 5:10 p.m.