tsVarToIndex: Converts a percentage variation series into a base 100 index...

Description Usage Arguments Details See Also Examples

Description

Compounds a percentage variation series into a 100 based index corresponding to the reference observation.

Usage

1
tsVarToIndex(x, base = 100, reference = 1)

Arguments

x

Time series to be converted to index.

base

(optional) Default is 100.

reference

(optional) Index of the observation to be used as reference. Default is 1 (first).

Details

The index is based in 100. Reference is by default the first observation.

See Also

dlog, tsNumToIndex

Examples

1
2
3
# Monthly inflation is around 2%
Inflation <- ts( rnorm(13,mean=2,sd=.5), start=c(2007,12), freq=12 )
CPI_dec07 <- tsVarToIndex( Inflation )

fcbarbi/macroR documentation built on May 16, 2019, 12:05 p.m.