From 8e58eb03e6ed8a6758ca14cfc60a1c8eb0a631b2 Mon Sep 17 00:00:00 2001 From: xinran Date: Tue, 20 Aug 2024 19:57:43 -0700 Subject: [PATCH] rd fix --- R/backtest.plot.R | 1 + man/backtest.plot.Rd | 2 ++ man/meancsm.efficient.frontier.Rd | 38 +++++++++++++++++++++++++++++++ 3 files changed, 41 insertions(+) create mode 100644 man/meancsm.efficient.frontier.Rd diff --git a/R/backtest.plot.R b/R/backtest.plot.R index 8a33fc8..3d31315 100644 --- a/R/backtest.plot.R +++ b/R/backtest.plot.R @@ -17,6 +17,7 @@ #' @param drawdown_on the plot will shadow the full time period of the maximum drawdown and recovery of the first portfolio. #' Use number (e.g. 1, 2, 3) to indicate which portfolio drawdown interval you wish to track, or NULL to not shadow any period. #' @param plotType "cumRet", "drawdown", or the default is both +#' @param main users can design title by providing a character of main #' @param colorSet users can design the color by providing a vector of color #' @param ltySet users can design lty by providing a vector of lty #' @param lwdSet users can design lwd by providing a vector of lwd diff --git a/man/backtest.plot.Rd b/man/backtest.plot.Rd index f127908..205542d 100644 --- a/man/backtest.plot.Rd +++ b/man/backtest.plot.Rd @@ -25,6 +25,8 @@ Use number (e.g. 1, 2, 3) to indicate which portfolio drawdown interval you wish \item{plotType}{"cumRet", "drawdown", or the default is both} +\item{main}{users can design title by providing a character of main} + \item{colorSet}{users can design the color by providing a vector of color} \item{ltySet}{users can design lty by providing a vector of lty} diff --git a/man/meancsm.efficient.frontier.Rd b/man/meancsm.efficient.frontier.Rd new file mode 100644 index 0000000..a180cfc --- /dev/null +++ b/man/meancsm.efficient.frontier.Rd @@ -0,0 +1,38 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/extract.efficient.frontier.R +\name{meancsm.efficient.frontier} +\alias{meancsm.efficient.frontier} +\title{Generate the efficient frontier for a mean-CSM portfolio} +\usage{ +meancsm.efficient.frontier( + portfolio, + R, + optimize_method = "CVXR", + n.portfolios = 25, + ... +) +} +\arguments{ +\item{portfolio}{a portfolio object with constraints and objectives created via \code{\link{portfolio.spec}}} + +\item{R}{an xts or matrix of asset returns} + +\item{optimize_method}{the optimize method to get the efficient frontier, default is CVXR} + +\item{n.portfolios}{number of portfolios to generate the efficient frontier} + +\item{\dots}{passthru parameters to \code{\link{optimize.portfolio}}} +} +\value{ +a matrix of objective measure values and weights along the efficient frontier +} +\description{ +This function generates the mean-CSM efficient frontier of a portfolio +specifying the constraints and objectives. The \code{portfolio} object +should have two objectives: 1) mean and 2) CSM. If the +portfolio object does not contain these objectives, they will be added +using default parameters. +} +\author{ +Xinran Zhao +}