jubilee.eqty_ols: Internal utility to calculate OLS regression for log total...

Description Usage Arguments Value Author(s) Examples

View source: R/jubilee-eqty-ols-method.R

Description

Calculate the OLS regression for log total return index

Usage

1
jubilee.eqty_ols(dtb, end.frac, lookback.channel, tol.frac = 1/6)

Arguments

dtb

data.table that contains fraction and log.tri columns.

end.frac

numeric, the ending fraction of regression.

lookback.channel

numeric, the backward-looking regression period

tol.frac

numeric, tolerance of missing data in the beginning, expressed as fraction. Default is 1/6, that is, two months.

Value

two-element array c(a,R) if end.frac is length-one; data.table with end.frac as fraction column if end.frac is an array.

Author(s)

Stephen H. Lihn

Examples

1
2
3
4
5
  ## Not run: 
    dtb <- jubilee.repo(online=FALSE)@ie
    jubilee.eqty_ols(dtb, 1970, 50) # c(11.8671626, 0.1008371)
 
## End(Not run)

jubilee documentation built on Jan. 24, 2020, 5:10 p.m.