tsoutliers (version 0.6-8)

outliers: Define Outliers in a Data Frame

Description

This function is an interface to create a data frame defining the type, observation and weight of outliers. The output is properly designed to be used as input to other functions such as outliers.effects and outliers.regressors.

Usage

outliers(type, ind, weight = NULL)

Value

A data frame.

Arguments

type

a character vector. The types of outliers ("IO", "AO", "LS", "TC", "SLS").

ind

a numeric vector. The observations at which each outlier takes effect.

weight

an optional numeric vector. The weights of the outliers. If NULL the weights are set equal to one.

Examples

Run this code
outliers(c("AO", "LS"), c(10, 20))
outliers(c("AO", "LS"), c(10, 20), c(2.1, 3.2))

Run the code above in your browser using DataCamp Workspace