frontier-plot | R Documentation |
Plots the efficient frontier of an optimized portfolio and allows to add points and lines from specif portfolios
frontierPlot(object, frontier = c("both", "lower", "upper"),
col = c("black", "grey"), add = FALSE, labels = TRUE,
return = c("mean", "mu"), risk = c("Cov", "Sigma", "CVaR", "VaR"),
auto = TRUE, title = TRUE, ...)
minvariancePoints(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
cmlPoints(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
cmlLines(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
tangencyPoints(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
tangencyLines(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
equalWeightsPoints(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
singleAssetPoints(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
twoAssetsLines(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
sharpeRatioLines(object, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
monteCarloPoints(object, mcSteps = 5000, return = c("mean", "mu"),
risk = c("Cov", "Sigma", "CVaR", "VaR"), auto = TRUE, ...)
tailoredFrontierPlot(object,
return = c("mean", "mu"), risk = c("Cov", "Sigma", "CVaR", "VaR"),
mText = NULL, col = NULL, xlim = NULL, ylim = NULL,
twoAssets = FALSE, sharpeRatio = TRUE, title = TRUE, ...)
object |
an S4 object of class |
frontier |
a character string, determining which part of the frontier should be
extracted. |
col |
a character string vector, setting the color. For |
add |
a logical value, determining whether the frontier should be added to an existing plot, by default FALSE. |
return |
a character string denoting which type of return should be
plotted. Allowed values for the
return are either |
risk |
a character string denoting which type of risk should be
plotted. Allowed values for the
risk measure are either |
auto |
a logical flag denoting if the type of return and risk to be plotted should be selected automatically, by default TRUE. |
labels |
a logical flag, should the plot be automatically labeled and
decorated? By default |
title |
a logical flag, should the plot obtain a default main title and
x- and y-labels? By default |
mcSteps |
an integer value, the number of Monte Carlo steps. |
xlim, ylim |
two numeric vectors with two elelemts , the plot range. If set to NULL the values for the plot ranges are determined automatically. |
mText |
a character string, representing a marginal text string. If set to NULL the value is taken from the title of the input frontier argument. |
twoAssets |
a logical flag, if TRUE, then the two assets frontier lines will be drawn. |
sharpeRatio |
a logical flag, if TRUE, then the Sharpe ratio will be added to the plot. |
... |
optional arguments to be passed. |
frontierPlot | Plots efficient frontier, |
minvariancePoints | Adds minimum variance point, |
cmlPoints | Adds market portfolio, |
cmlLines | Adds capital market Line, |
tangencyPoints | Adds tangency portfolio point, |
tangencyLines | Adds tangency line, |
equalWeightsPoints | Adds point of equal weights portfolio, |
singleAssetPoints | Adds points of single asset portfolios, |
twoAssetsLines | Adds EF for all combinations of two assets, |
sharpeRatioLines | Adds Sharpe ratio line, |
monteCarloPoints | Adds randomly produced feasible portfolios, |
tailoredFrontierPlot | an example for a tailored plot. |
Wuertz, D., Chalabi, Y., Chen W., Ellis A. (2009); Portfolio Optimization with R/Rmetrics, Rmetrics eBook, Rmetrics Association and Finance Online, Zurich.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.