bankrotation: bank rotation

Description Usage Arguments Value Author(s) Examples

Description

This is a bank stocks rotation strategy.Its idea comes from https://www.jisilu.cn/question/50176.

Usage

1
2
3
4
5
6
bank.rotation(begT, endT = Sys.Date() - 1, chgBar = 0.2, fee = 0.003,
  pbfun = c("gf.PB_lyr", "gf.PB_mrq"), roefun = c("gf.ROE_ttm", "gf.ROE",
  "gf.F_ROE"))

bank.rotationV2(begT, endT, FactorLists, chgBar, fee = 0.003,
  sectorID = "ES33480000", prefer = FALSE)

Arguments

begT

is strategy's begin date

endT

is strategy's end date

chgBar

is rotation's bar

fee

is trading cost

Value

a list of bank factorscore and strategy's historical return.

Author(s)

Andrew Dow

Examples

1
2
3
4
5
6
7
8
begT <- as.Date('2014-01-03')
endT <- Sys.Date()-1
chgBar <- 0.2
bankport <- bank.rotation(begT,endT,chgBar)
FactorLists <- list(
  buildFactorList(factorFun='gf.PB_mrq'),
  buildFactorList(factorFun='gf.ROE_ttm'))
re <- bank.rotationV2(begT,endT,FactorLists=FactorLists)

QuantAndrew/quantbox documentation built on May 8, 2019, 3:50 a.m.