Learn R Programming

utsf (version 1.1.0)

trend: Specifying the transformation for dealing with trended series

Description

This function is used to specify the preprocessing associated with the trend of a time series.

Usage

trend(type = "additive", n = -1)

Value

A list with the selected options

Arguments

type

A character indicating the type of preprocessing applied to the time series. Possible values are: "none, "additive", "multiplicative" and "differences".

n

An integer specifying the order of first differences to be applied. If the default (-1) is used, the order of first differences needed by the time series will be estimated by the forecast::ndiffs() function. This parameter is only meant when the type parameter is "differences".

Examples

Run this code
trend("none")            # no preprocessing
trend("additive")        # additive preprocessing
trend("differences", 1)  # order 1 first differences
trend("differences", -1) # number of first differences estimated

Run the code above in your browser using DataLab