Table of Contents

Class QuickStats

Namespace
Balsam.Portfolio
Assembly
Balsam.Backtester.dll

Calculates a few simple portfolio metrics on a return stream with as low an overhead as possible.

[ProtoContract(SkipConstructor = true)]
public class QuickStats
Inheritance
QuickStats
Inherited Members
Extension Methods

Constructors

QuickStats(IEnumerable<double>, double, int)

Initializes a new QuickStats object using the specified parameters.

public QuickStats(IEnumerable<double> returns, double riskFreeRate = 0, int periodsPerYear = 252)

Parameters

returns IEnumerable<double>
riskFreeRate double
periodsPerYear int

Properties

ArithmeticSharpeRatio

Gets the arithmetic Sharpe Ratio (mean return * periods period year - risk free rate) / volatility.

public double ArithmeticSharpeRatio { get; }

Property Value

double

CAGR

Gets the compound annual growth rate.

public double CAGR { get; }

Property Value

double

MARRatio

Gets the MAR Ratio.

public double MARRatio { get; }

Property Value

double

MaxDrawdown

Gets the maximum drawdown.

public double MaxDrawdown { get; }

Property Value

double

MaxDrawdownPeriod

Gets the length of the max drawdown until recovery.

public int MaxDrawdownPeriod { get; }

Property Value

int

PeriodsPerYear

Gets the number of periods per year.

public int PeriodsPerYear { get; }

Property Value

int

RiskFreeRate

Gets the risk free rate.

public double RiskFreeRate { get; }

Property Value

double

SharpeRatio

Gets the Sharpe Ratio.

public double SharpeRatio { get; }

Property Value

double

StandardDeviation

Gets the standard deviation.

public double StandardDeviation { get; }

Property Value

double

UlcerIndex

Gets the Ulcer Index.

public double UlcerIndex { get; }

Property Value

double

UlcerPerformanceIndex

Gets the Ulcer Performance Index.

public double UlcerPerformanceIndex { get; }

Property Value

double

Volatility

Gets the annualized volatility.

public double Volatility { get; }

Property Value

double

Methods

ToString()

Returns some key summary statistics.

public override string ToString()

Returns

string