Description Usage Arguments Details Value Author(s) See Also Examples
The transaction cost constraint specifies a proportional
cost value. This function is called by add.constraint
when type="transaction_cost" is specified, see
add.constraint
.
1 2 |
type |
character type of the constraint |
assets |
number of assets, or optionally a named vector of assets specifying initial weights |
ptc |
proportional transaction cost 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 |
Note that with the ROI solvers, proportional transaction cost constraint is currently only supported for the global minimum variance and quadratic utility problems with ROI quadprog plugin.
an object of class 'transaction_cost_constraint'
Ross Bennett
1 2 3 4 5 6 | data(edhec)
ret <- edhec[, 1:4]
pspec <- portfolio.spec(assets=colnames(ret))
pspec <- add.constraint(portfolio=pspec, type="transaction_cost", ptc=0.01)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.