gg_charts_summary_3: Produces a plot of cumulative performance, returns, and...

Description Usage Arguments Value See Also Examples

View source: R/gg_charts_3.R

Description

Produces a plot of cumulative performance, returns, and drawdown over time given a history of returns.

Usage

1
gg_charts_summary_3(r.xts, ptitle = "", geometric = TRUE)

Arguments

r.xts

an XTS object with period returns for each column; function will compute cumulative return and drawdowns for each item.

ptitle

a plot title string, default empty string

geometric

whether cumulative returns should use geometric method

Value

ggplot2 object for further manipulation

See Also

PerformanceAnalytics::charts.PerformanceSummary, directlabels, dplyr, tidyr, magrittr, ggplot2

Examples

1
2
3
4
5
6
7
8
9
## Not run: 
pr <- blotter::PortfReturns(acct_name)
colnames(pr) <- gsub(".DailyEndEq", "", colnames(pr))
pr$Theoretical <- rowSums(pr)
p <-gg_charts_summary_3(pr$Theoretical,
                       ptitle = "Theoretical Returns")
p

## End(Not run)

greatgray/scorecard documentation built on May 17, 2019, 8:34 a.m.