get.longrun.growth {tdata} | R Documentation |
Calculate Long-run Growth
Description
Use this function to calculate the long-run growth of a time-series data.
Usage
get.longrun.growth(
data,
continuous = FALSE,
isPercentage = FALSE,
trimStart = 0,
trimEnd = 0,
skipZero = TRUE
)
Arguments
data |
A numeric vector that represents the data of the series. |
continuous |
A logical value indicating whether to use the continuous formula. |
isPercentage |
A logical value indicating whether the unit of measurement in |
trimStart |
If the number of leading |
trimEnd |
Similar to |
skipZero |
If |
Details
A variable can have discrete growth ()
or continuous growth (
) over
periods.
is the first value and
is the last value.
By long-run growth rate, we mean a number such as
such that if
we start from
and the variable growth is
every period,
we reach
after t periods. This number summarizes all
s,
however, it is not generally the average of these rates.
Value
The long-run growth rate (percentage).
Examples
y <- c(60, 70, 80, 95)
g <- get.longrun.growth(y, isPercentage = TRUE, continuous = FALSE)
# Note that 'g' is different from 'mean(y)'.