PerformanceAnalytics v2.0.4


Monthly downloads



Functions in PerformanceAnalytics

Name Description
AverageDrawdown Calculates the average depth of the observed drawdowns.
CAPM.alpha calculate single factor model (CAPM) alpha
CoMoments Functions for calculating comoments of financial time series
CalmarRatio calculate a Calmar or Sterling reward/risk ratio Calmar and Sterling Ratios are yet another method of creating a risk-adjusted measure for ranking investments similar to the SharpeRatio.
ETL calculates Expected Shortfall(ES) (or Conditional Value-at-Risk(CVaR) for univariate and component, using a variety of analytical methods.
DrawdownPeak Drawdawn peak of the return distribution
M2Sortino M squared for Sortino of the return distribution
CDD Calculate Uryasev's proposed Conditional Drawdown at Risk (CDD or CDaR) measure
InformationRatio InformationRatio = ActivePremium/TrackingError
MCA Functions for doing Moment Component Analysis (MCA) of financial time series
CAPM.jensenAlpha Jensen's alpha of the return distribution
CAPM.dynamic Time-varying conditional single factor model beta
CAPM.beta calculate single factor model (CAPM) beta
PainRatio Pain ratio of the return distribution
DownsideFrequency downside frequency of the return distribution
DrawdownDeviation Calculates a standard deviation-type statistic using individual drawdowns.
CAPM.epsilon Regression epsilon of the return distribution
MarketTiming Market timing models
MartinRatio Martin ratio of the return distribution
SkewnessKurtosisRatio Skewness-Kurtosis ratio of the return distribution
Kappa Kappa of the return distribution
NetSelectivity Net selectivity of the return distribution
UlcerIndex calculate the Ulcer Index
MSquared M squared of the return distribution
Selectivity Selectivity of the return distribution
MSquaredExcess M squared excess of the return distribution
VaR calculate various Value at Risk (VaR) measures
Modigliani Modigliani-Modigliani measure
Return.clean clean returns in a time series to to provide more robust risk estimates
SmoothingIndex calculate Normalized Getmansky Smoothing Index
chart.Bar wrapper for barchart of returns
Return.convert Convert coredata content from one type of return to another
UpsideFrequency upside frequency of the return distribution
charts.RollingPerformance rolling performance chart
TreynorRatio calculate Treynor Ratio or modified Treynor Ratio of excess return over CAPM beta
UpDownRatios calculate metrics on up and down markets for the benchmark asset
Return.Geltner calculate Geltner liquidity-adjusted return series
DRatio d ratio of the return distribution
SortinoRatio calculate Sortino Ratio of performance over downside risk
checkData check input data type and format and coerce to the desired output type
chart.SnailTrail chart risk versus return over rolling time periods
skewness Skewness
chart.Scatter wrapper to draw scatter plot with sensible defaults
table.RollingPeriods Rolling Periods Summary: Statistics and Stylized Facts
chart.BarVaR Periodic returns in a bar chart with risk metric overlay
table.Correlation calculate correlalations of multicolumn data
PerformanceAnalytics-package Econometric tools for performance and risk analysis.
EWMAMoments Functions for calculating EWMA comoments of financial time series
sortDrawdowns order list of drawdowns from worst to best
DownsideDeviation downside risk (deviation, variance) of the return distribution
apply.fromstart calculate a function over an expanding window always starting from the beginning of the series
Return.annualized calculate an annualized return for comparing instruments with different length history
zerofill zerofill
table.Arbitrary wrapper function for combining arbitrary function list into a table
Return.annualized.excess calculates an annualized excess return for comparing instruments with different length history
Frequency Frequency of the return distribution
Return.portfolio Calculate weighted returns for a portfolio of assets
table.Distributions Distributions Summary: Statistics and Stylized Facts
FamaBeta Fama beta of the return distribution
Omega calculate Omega for a return series
Return.cumulative calculate a compounded (geometric) cumulative return
table.SpecificRisk Specific risk Summary: Statistics and Stylized Facts
Return.locScaleRob Robust Filter for Time Series Returns
KellyRatio calculate Kelly criterion ratio (leverage or bet size) for a strategy
OmegaSharpeRatio Omega-Sharpe ratio of the return distribution
PainIndex Pain index of the return distribution
HurstIndex calculate the Hurst Index The Hurst index can be used to measure whether returns are mean reverting, totally random, or persistent.
table.CalendarReturns Monthly and Calendar year Return table
SharpeRatio calculate a traditional or modified Sharpe Ratio of Return over StdDev or VaR or ES
chart.Events Plots a time series with event dates aligned
Return.excess Calculates the returns of an asset in excess of the given risk free rate
StdDev.annualized calculate a multiperiod or annualized Standard Deviation
MeanAbsoluteDeviation Mean absolute deviation of the return distribution
chart.CaptureRatios Chart of Capture Ratios against a benchmark
Level.calculate Calculate appropriate cumulative return series or asset level using xts attribute information
SharpeRatio.annualized calculate annualized Sharpe Ratio
StdDev calculates Standard Deviation for univariate and multivariate series, also calculates component contribution to standard deviation of a portfolio
TotalRisk Total risk of the return distribution
prices Selected Price Series Example Data
chart.CumReturns Cumulates and graphs a set of periodic returns
chart.Correlation correlation matrix chart
SpecificRisk Specific risk of the return distribution
apply.rolling calculate a function over a rolling window
portfolio_bacon Bacon(2008) Data
chart.RollingQuantileRegression A wrapper to create charts of relative regression performance through time
chart.VaRSensitivity show the sensitivity of Value-at-Risk or Expected Shortfall estimates
chart.RollingPerformance wrapper to create a chart of rolling performance metrics in a line chart
table.AnnualizedReturns Annualized Returns Summary: Statistics and Stylized Facts
charts.PerformanceSummary Create combined wealth index, period performance, and drawdown chart
MinTrackRecord Minimum Track Record Length
ProbSharpeRatio Probabilistic Sharpe Ratio
clean.boudt clean extreme observations in a time series to to provide more robust risk estimates
OmegaExcessReturn Omega excess return of the return distribution
table.Variability Variability Summary: Statistics and Stylized Facts
ShrinkageMoments Functions for calculating shrinkage-based comoments of financial time series
Return.calculate calculate simple or compound returns from prices Read returns data with different date formats
test_returns Sample sector returns for use by unit tests
VolatilitySkewness Volatility and variability of the return distribution
UpsidePotentialRatio calculate Upside Potential Ratio of upside performance over downside risk
chart.QQPlot Plot a QQ chart
kurtosis Kurtosis
chart.Histogram histogram of returns
checkSeedValue Check 'seedValue' to ensure it is compatible with coredata_content attribute of 'R' (an xts object)
ProspectRatio Prospect ratio of the return distribution
chart.StackedBar create a stacked bar plot
RPESE.control Controls Function for the Computation of Standard Errors for Risk and Performance estimators
chart.Regression Takes a set of returns and relates them to a market benchmark in a scatterplot
Return.relative calculate the relative return of one asset to another
StructuredMoments Functions for calculating structured comoments of financial time series
RachevRatio Standard Error Estimate for Rachev Ratio of Returns
chart.RollingCorrelation chart rolling correlation fo multiple assets
SystematicRisk Systematic risk of the return distribution
chart.ACF Create ACF chart or ACF with PACF two-panel chart
chart.Drawdown Time series chart of drawdowns through time
TrackingError Calculate Tracking Error of returns against a benchmark
UpsideRisk upside risk, variance and potential of the return distribution
chart.ECDF Create an ECDF overlaid with a Normal CDF
chart.RelativePerformance relative performance chart between multiple return series
chart.RiskReturnScatter scatter chart of returns vs risk for comparing multiple instruments
table.Drawdowns Worst Drawdowns Summary: Statistics and Stylized Facts
legend internal functions for setting useful defaults for graphs
table.Autocorrelation table for calculating the first six autocorrelation coefficients and significance
Drawdowns Find the drawdowns and drawdown levels in a timeseries.
maxDrawdown caclulate the maximum drawdown from peak equity
edhec EDHEC-Risk Hedge Fund Style Indices
table.SFM Single Factor Asset-Pricing Model Summary: Statistics and Stylized Facts
table.CaptureRatios Calculate and display a table of capture ratio and related statistics
mean.geometric calculate attributes relative to the mean of the observation series given, including geometric, stderr, LCL and UCL
table.HigherMoments Higher Moments Summary: Statistics and Stylized Facts
table.DrawdownsRatio Drawdowns Summary: Statistics and ratios
Return.centered calculate centered Returns
chart.Boxplot box whiskers plot wrapper
chart.RollingMean chart the rolling mean return
chart.TimeSeries Creates a time series chart with some extensions.
table.DownsideRiskRatio Downside Summary: Statistics and ratios
lpm calculate a lower partial moment for a time series
table.InformationRatio Information ratio Summary: Statistics and Stylized Facts
table.Stats Returns Summary: Statistics and Stylized Facts
managers Hypothetical Alternative Asset Manager and Benchmark Data
table.DownsideRisk Downside Risk Summary: Statistics and Stylized Facts
to.period.contributions Aggregate contributions through time
table.ProbOutPerformance Outperformance Report of Asset vs Benchmark
replaceTabs.inner Display text information in a graphics plot.
test_weights Sample sector weights for use by unit tests
weights Selected Portfolio Weights Data
ActiveReturn Active Premium or Active Return
AppraisalRatio Appraisal ratio of the return distribution
BurkeRatio Burke ratio of the return distribution
AdjustedSharpeRatio Adjusted Sharpe ratio of the return distribution
CAPM.CML.slope utility functions for single factor (CAPM) CML, SML, and RiskPremium
BernardoLedoitRatio Bernardo and Ledoit ratio of the return distribution
BetaCoMoments Functions to calculate systematic or beta co-moments of return series
AverageRecovery Calculates the average length (in periods) of the observed recovery period.
AverageLength Calculates the average length (in periods) of the observed drawdowns.
No Results!

Vignettes of PerformanceAnalytics

No Results!

Last month downloads



Include our badge in your README