specFfm: Specifies the elements of a fundamental factor model

View source: R/fitFfmDT.R

specFfmR Documentation

Specifies the elements of a fundamental factor model

Description

Factor models have a few parameters that describe how the fitting is done. This function summarizes them and returns a spec object for cross-sectional regressions. It also preps the data. An object of class "ffmSpec" is returned.

Usage

specFfm(
  data,
  asset.var,
  ret.var,
  date.var,
  exposure.vars,
  weight.var = NULL,
  addIntercept = FALSE,
  rob.stats = FALSE
)

Arguments

data

data.frame of the balanced panel data containing the variables asset.var, ret.var, exposure.vars, date.var and optionally, weight.var.

asset.var

character; name of the variable for asset names.

ret.var

character; name of the variable for asset returns.

date.var

character; name of the variable containing the dates coercible to class Date.

exposure.vars

vector; names of the variables containing the fundamental factor exposures.

weight.var

character; name of the variable containing the weights used when standarizing style factor exposures. Default is NULL. See Details.

addIntercept

logical; If TRUE, intercept is added in the exposure matrix. Default is FALSE,

rob.stats

logical; If TRUE, robust estimates of covariance, correlation, location and univariate scale are computed as appropriate (see Details). Default is FALSE.


braverock/factorAnalytics documentation built on March 2, 2024, 11:17 p.m.