Lean  $LEAN_TAG$
QuantConnect.Indicators.ValueAtRisk Class Reference

This indicator computes 1-day VaR for a specified confidence level and lookback period More...

Inheritance diagram for QuantConnect.Indicators.ValueAtRisk:
[legend]

Public Member Functions

 ValueAtRisk (string name, int period, double confidenceLevel)
 Creates a new ValueAtRisk indicator with a specified period and confidence level More...
 
 ValueAtRisk (int period, double confidenceLevel)
 Creates a new ValueAtRisk indicator with a specified period and confidence level More...
 
override void Reset ()
 Resets this indicator to its initial state More...
 
- Public Member Functions inherited from QuantConnect.Indicators.WindowIndicator< IndicatorDataPoint >
override void Reset ()
 Resets this indicator to its initial state More...
 

Public Attributes

override bool IsReady => Samples >= WarmUpPeriod
 Gets a flag indicating when the indicator is ready and fully initialized More...
 
- Public Attributes inherited from QuantConnect.Indicators.WindowIndicator< IndicatorDataPoint >
int Period
 Gets the period of this window indicator More...
 
override bool IsReady
 Gets a flag indicating when this indicator is ready and fully initialized More...
 
virtual int WarmUpPeriod
 Required period, in data points, to the indicator to be ready and fully initialized More...
 

Protected Member Functions

override decimal ComputeNextValue (IReadOnlyWindow< IndicatorDataPoint > window, IndicatorDataPoint input)
 Computes the next value for this indicator from the given state. More...
 
- Protected Member Functions inherited from QuantConnect.Indicators.WindowIndicator< IndicatorDataPoint >
 WindowIndicator (string name, int period)
 Initializes a new instance of the WindowIndicator class More...
 
override decimal ComputeNextValue (T input)
 Computes the next value of this indicator from the given state More...
 
abstract decimal ComputeNextValue (IReadOnlyWindow< T > window, T input)
 Computes the next value for this indicator from the given state. More...
 

Properties

override int WarmUpPeriod [get]
 Required period, in data points, for the indicator to be ready and fully initialized. More...
 
- Properties inherited from QuantConnect.Indicators.IIndicatorWarmUpPeriodProvider
int WarmUpPeriod [get]
 Required period, in data points, for the indicator to be ready and fully initialized. More...
 

Detailed Description

This indicator computes 1-day VaR for a specified confidence level and lookback period

Definition at line 25 of file ValueAtRisk.cs.

Constructor & Destructor Documentation

◆ ValueAtRisk() [1/2]

QuantConnect.Indicators.ValueAtRisk.ValueAtRisk ( string  name,
int  period,
double  confidenceLevel 
)

Creates a new ValueAtRisk indicator with a specified period and confidence level

Parameters
nameThe name of this indicator
periodHistorical lookback period in days
confidenceLevelConfidence level for VaR calculation

Definition at line 58 of file ValueAtRisk.cs.

◆ ValueAtRisk() [2/2]

QuantConnect.Indicators.ValueAtRisk.ValueAtRisk ( int  period,
double  confidenceLevel 
)

Creates a new ValueAtRisk indicator with a specified period and confidence level

Parameters
periodHistorical lookback period in days
confidenceLevelConfidence level for VaR calculation

Definition at line 78 of file ValueAtRisk.cs.

Member Function Documentation

◆ ComputeNextValue()

override decimal QuantConnect.Indicators.ValueAtRisk.ComputeNextValue ( IReadOnlyWindow< IndicatorDataPoint window,
IndicatorDataPoint  input 
)
protected

Computes the next value for this indicator from the given state.

Parameters
windowThe window of data held in this indicator
inputThe input value to this indicator on this time step
Returns
A new value for this indicator

Definition at line 89 of file ValueAtRisk.cs.

◆ Reset()

override void QuantConnect.Indicators.ValueAtRisk.Reset ( )

Resets this indicator to its initial state

Definition at line 107 of file ValueAtRisk.cs.

Member Data Documentation

◆ IsReady

override bool QuantConnect.Indicators.ValueAtRisk.IsReady => Samples >= WarmUpPeriod

Gets a flag indicating when the indicator is ready and fully initialized

Definition at line 50 of file ValueAtRisk.cs.

Property Documentation

◆ WarmUpPeriod

override int QuantConnect.Indicators.ValueAtRisk.WarmUpPeriod
get

Required period, in data points, for the indicator to be ready and fully initialized.

Definition at line 45 of file ValueAtRisk.cs.


The documentation for this class was generated from the following file: