chktrans: Check for Possible Non-linear Transformations of a Multiple...

chktransR Documentation

Check for Possible Non-linear Transformations of a Multiple Time Series

Description

Check for possible non-linear transformations of a multiple time series, series by series.

Usage

chktrans(x, block = 0, output = FALSE, period = 1, pv = 0.05)

Arguments

x

T by k data matrix: T data points in rows with each row being data at a given time point, and k time series in columns.

block

Number of blocks used in the linear regression. Default value is floor(sqrt(T)).

output

If TRUE it returns the estimates, the code: log, sqrt and No-trans and the numbers of non-linear transformations. Default is TRUE.

period

Seasonal period.

pv

P-value = pv/log(1 + k) is used to check the significance of the coefficients. Default value is 0.05.

Details

Each series is divided into a given number of consecutive blocks and in each of them the mean absolute deviation (MAD) and the median are computed. A regression of the log of the MAD with respect to the log of the median is run and the slope defines the non-linear transformation.

Value

A list containing:

  • lnTran - Column locations of series that require log-transformation.

  • sqrtTran - Column locations of series that require square-root transformation.

  • noTran - Column locations of series that require no transformation.

  • tran - A vector indicating checking results, where 0 means no transformation, 1 means log-transformation, 2 means square-root transformation.

  • tranX Transformed series. This is only provided if the number of series requiring transformation is sufficiently large, i.e. greater than 2kpv.

  • Summary Number of time series that require log-transformation, square-root transformation and no transformation.

Examples

data(TaiwanAirBox032017)
output <- chktrans(TaiwanAirBox032017[,1])


SLBDD documentation built on April 27, 2022, 5:08 p.m.

Related to chktrans in SLBDD...