estimateDrift: The function estimates functional or scalar drift.

Usage Arguments Details Author(s)

Usage

1
estimateDrift(.formula, .g, .type = "OLS", Intercept = TRUE, regCoef = 0)

Arguments

.formula

- formula specifying which variables to use for drift;

.g

- an fstat structure containing all data.

.type

- drift type (OLS, GLS, MEAN)

.regCoef

- Regularization coefficient (just like in ridge regression)

Details

It adds a "drift" slot to the fstat structure (.g) with the following components: Betas - Coefficients assigned to each variable specified by the formula; Design matrix - A design matrix for each variable (useful for UK); Residuals - Functional or scalar residuals;

This code does not implement functional regression (Ramsay and Silverman, 2005), instead it fits one regression for each time step (piece-wise). The actual functional regression will be implemented in future version(s).

for .type=MEAN it just subtracts the mean from the functional data.

Author(s)

Ogy Grujic (ogyg@stanford.edu) and Alessandra Menafoglio (alessandra.menafoglio@polimi.it)


ogru/fdagstat documentation built on May 29, 2019, 7:19 a.m.