momentum_factor-methods: Construct momentum factor

Description Usage Arguments Value References

Description

Provided with futures contract front or equity price data from Bloomberg retrieved with pullit, construct momentum factor. The momentum factor sorts on prior asset returns and is popular in the equity \insertCitecarhart1997persistence,fama2012sizefactorem as well as commodity futures \insertCitemiffre2007momentumfactorem asset pricing literature.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
momentum_factor(
  data,
  update_frequency = "week",
  return_frequency = "day",
  ranking_period = 4L,
  long_threshold = 0.5,
  short_threshold = 0.5,
  weighted = F,
  risk_adjusted = F
)

## S4 method for signature 'FuturesTS'
momentum_factor(
  data,
  update_frequency = "week",
  return_frequency = "day",
  ranking_period = 4L,
  long_threshold = 0.5,
  short_threshold = 0.5,
  weighted = F,
  risk_adjusted = F
)

## S4 method for signature 'EquityMarket'
momentum_factor(
  data,
  update_frequency = "week",
  return_frequency = "day",
  ranking_period = 4L,
  long_threshold = 0.5,
  short_threshold = 0.5,
  weighted = F,
  risk_adjusted = F
)

Arguments

data

an S4 object of class FuturesTS or EquityMarket. FuturesTS and EquityMarket objects are returned by the BBG_futures_TS and BBG_equity_market functions from the pullit package respectively.

update_frequency

a scalar character vector. Specifies the rebalancing frequency. Must be one of 'year', 'semester', 'quarter', 'month' or 'week'. Defaults to 'month'.

return_frequency

a scalar character vector. Specifies the frequency of the returns output. Must be one of 'year', 'semester', 'quarter', 'month', 'week' or 'day'. Defaults to 'day'.

ranking_period

a scalar integer vector. Specifies number of periods in term of update_frequency looking backward for average price return calculation. Defaults to 1 where sort is done on last observed return.

long_threshold

a scalar numeric vector. Specifies the threshold for short positions. Default: 0.5.

short_threshold

a scalar numeric vector. Specifies the threshold for long positions. Default: 0.5.

weighted

a scalar logical vector. If 'TRUE' adjusts portoflio weights with respect to sorting variable values, else equal weights are used. Defaults to 'FALSE'.

risk_adjusted

a scalar logical vector. If 'TRUE' returns a reward/risk mometum factor, else returns a classic momentum factor. Defaults to 'FALSE'.

Value

An S4 object of class MomentumFactor.

References

\insertAllCited
bautheac/factorem documentation built on June 7, 2021, 12:11 p.m.