Lean  $LEAN_TAG$
QuantConnect.Indicators.RelativeMovingAverage Class Reference

Represents the relative moving average indicator (RMA). RMA = SMA(3 x Period) - SMA(2 x Period) + SMA(1 x Period) per formula: https://www.hybrid-solutions.com/plugins/client-vtl-plugins/free/rma.html More...

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

Public Member Functions

 RelativeMovingAverage (string name, int period)
 Initializes a new instance of the RelativeMovingAverage class with the specified name and period More...
 
 RelativeMovingAverage (int period)
 Initializes a new instance of the SimpleMovingAverage class with the default name and period More...
 
override void Reset ()
 Resets this indicator to its initial state More...
 

Public Attributes

override bool IsReady => LongAverage.IsReady
 Gets a flag indicating when this indicator is ready and fully initialized More...
 
int WarmUpPeriod => LongAverage.WarmUpPeriod
 Required period, in data points, for the indicator to be ready and fully initialized. More...
 

Protected Member Functions

override decimal ComputeNextValue (IndicatorDataPoint input)
 Copmutes the next value for this indicator from the given state. More...
 
- Protected Member Functions inherited from QuantConnect.Indicators.Indicator
 Indicator (string name)
 Initializes a new instance of the Indicator class using the specified name. More...
 

Properties

SimpleMovingAverage ShortAverage [get]
 Gets the Short Term SMA with 1 x Period of RMA More...
 
SimpleMovingAverage MediumAverage [get]
 Gets the Medium Term SMA with 2 x Period of RMA More...
 
SimpleMovingAverage LongAverage [get]
 Gets the Long Term SMA with 3 x Period of RMA More...
 
- Properties inherited from QuantConnect.Indicators.Indicator
static int DefaultWindowSize = 2 [get]
 The default size of the history window for the indicator 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

Represents the relative moving average indicator (RMA). RMA = SMA(3 x Period) - SMA(2 x Period) + SMA(1 x Period) per formula: https://www.hybrid-solutions.com/plugins/client-vtl-plugins/free/rma.html

Definition at line 23 of file RelativeMovingAverage.cs.

Constructor & Destructor Documentation

◆ RelativeMovingAverage() [1/2]

QuantConnect.Indicators.RelativeMovingAverage.RelativeMovingAverage ( string  name,
int  period 
)

Initializes a new instance of the RelativeMovingAverage class with the specified name and period

Parameters
nameThe name of this indicator
periodThe period of the RMA

Definition at line 55 of file RelativeMovingAverage.cs.

◆ RelativeMovingAverage() [2/2]

QuantConnect.Indicators.RelativeMovingAverage.RelativeMovingAverage ( int  period)

Initializes a new instance of the SimpleMovingAverage class with the default name and period

Parameters
period

Definition at line 67 of file RelativeMovingAverage.cs.

Member Function Documentation

◆ ComputeNextValue()

override decimal QuantConnect.Indicators.RelativeMovingAverage.ComputeNextValue ( IndicatorDataPoint  input)
protected

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

Parameters
inputThe input value to this indicator on this time step
Returns
A new value for this indicator

Definition at line 77 of file RelativeMovingAverage.cs.

◆ Reset()

override void QuantConnect.Indicators.RelativeMovingAverage.Reset ( )

Resets this indicator to its initial state

Definition at line 89 of file RelativeMovingAverage.cs.

Here is the call graph for this function:

Member Data Documentation

◆ IsReady

override bool QuantConnect.Indicators.RelativeMovingAverage.IsReady => LongAverage.IsReady

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

Definition at line 43 of file RelativeMovingAverage.cs.

◆ WarmUpPeriod

int QuantConnect.Indicators.RelativeMovingAverage.WarmUpPeriod => LongAverage.WarmUpPeriod

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

Definition at line 48 of file RelativeMovingAverage.cs.

Property Documentation

◆ ShortAverage

SimpleMovingAverage QuantConnect.Indicators.RelativeMovingAverage.ShortAverage
get

Gets the Short Term SMA with 1 x Period of RMA

Definition at line 28 of file RelativeMovingAverage.cs.

◆ MediumAverage

SimpleMovingAverage QuantConnect.Indicators.RelativeMovingAverage.MediumAverage
get

Gets the Medium Term SMA with 2 x Period of RMA

Definition at line 33 of file RelativeMovingAverage.cs.

◆ LongAverage

SimpleMovingAverage QuantConnect.Indicators.RelativeMovingAverage.LongAverage
get

Gets the Long Term SMA with 3 x Period of RMA

Definition at line 38 of file RelativeMovingAverage.cs.


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