Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

turnover_constraint

constructor for turnover_constraint


Description

The turnover constraint specifies a target turnover value. This function is called by add.constraint when type="turnover" is specified, see add.constraint. Turnover is calculated from a set of initial weights. Turnover is computed as sum(abs(initial_weights - weights)) / N where N is the number of assets.

Usage

turnover_constraint(type = "turnover", turnover_target, enabled = TRUE,
  message = FALSE, ...)

Arguments

type

character type of the constraint

turnover_target

target turnover value

enabled

TRUE/FALSE

message

TRUE/FALSE. The default is message=FALSE. Display messages if TRUE.

...

any other passthru parameters to specify box and/or group constraints

Details

Note that with the ROI solvers, turnover constraint is currently only supported for the global minimum variance and quadratic utility problems with ROI quadprog plugin.

Value

an object of class 'turnover_constraint'

Author(s)

Ross Bennett

See Also

Examples

data(edhec)
ret <- edhec[, 1:4]

pspec <- portfolio.spec(assets=colnames(ret))

pspec <- add.constraint(portfolio=pspec, type="turnover", turnover_target=0.6)

PortfolioAnalytics

Portfolio Analysis, Including Numerical Methods for Optimization of Portfolios

v1.1.0
GPL-2 | GPL-3
Authors
Brian G. Peterson [cre, aut, cph], Peter Carl [aut, cph], Kris Boudt [ctb, cph], Ross Bennett [ctb, cph], Hezky Varon [ctb], Guy Yollin [ctb], R. Douglas Martin [ctb]
Initial release
2018-05-17

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.