| pputil.fourmoments {pprobeSup} | R Documentation |
Returns a utility based on the scenarios that combines the first four moments via the parameters – a value for each random portfolio.
pputil.fourmoments(rp, scenarios, parameters, level = NULL, verbose = FALSE)
rp |
a random portfolio object. |
scenarios |
a three-dimensional array: times in rows, assets in columns and scenarios in the third dimension. |
parameters |
length 3 numeric vector that is coefficients for the variance, skewness and kurtosis. Normally the first and third should be negative and the second positive. |
level |
if Otherwise, should be a number between 0 and 1 giving the quantile of the utility to return. |
verbose |
logical value, if |
a numeric vector as long as the number of random portfolios. The utility for each portfolio and scenario is the mean log return (across time) plus the first parameter times the variance plus the second parameter times the skewness plus the third parameter times the kurtosis.
The value for each portfolio is the mean or level quantile
of the utilities across scenarios.
if verbose is TRUE, then printing is done.
In test suite, mildly tested.
This help file was last revised 2013 May 02.
scenario.optimizer, pputil.meanvar,
pputil.omega, pputil.value.
fmOpt <- scenario.optimizer(multipleTimesScen,
utility=pputil.fourmoments,
extraArgs=list(parameters=c(-.8, 1, -.2)),
max.weight=.04, gross=1e7, long.only=TRUE, port.size=50,
existing=currentHoldings)