|
Lean
$LEAN_TAG$
|
Represents the Average Range (AR) indicator, which calculates the average price range More...
Public Member Functions | |
| AverageRange (string name, int period) | |
| Initializes a new instance of the AverageRange class with the specified name and period. More... | |
| AverageRange (int period) | |
| Initializes the AR indicator with the default name format and period. More... | |
| override void | Reset () |
| Resets the indicator and clears the internal state, including the SMA. More... | |
Public Attributes | |
| override bool | IsReady => _sma.IsReady |
| Indicates whether the indicator has enough data to start producing valid results. More... | |
| int | WarmUpPeriod => _sma.WarmUpPeriod |
| The number of periods needed to fully initialize the AR indicator. More... | |
Protected Member Functions | |
| override decimal | ComputeNextValue (IBaseDataBar input) |
| Computes the next value of the Average Range (AR) by calculating the price range (high - low) and passing it to the SMA to get the smoothed value. More... | |
Protected Member Functions inherited from QuantConnect.Indicators.BarIndicator | |
| BarIndicator (string name) | |
| Creates a new TradeBarIndicator with the specified name More... | |
Additional Inherited Members | |
Properties inherited from QuantConnect.Indicators.IIndicatorWarmUpPeriodProvider | |
| int | WarmUpPeriod [get] |
| Required period, in data points, for the indicator to be ready and fully initialized. More... | |
Represents the Average Range (AR) indicator, which calculates the average price range
Definition at line 23 of file AverageRange.cs.
| QuantConnect.Indicators.AverageRange.AverageRange | ( | string | name, |
| int | period | ||
| ) |
Initializes a new instance of the AverageRange class with the specified name and period.
| name | The name of the AR indicator. |
| period | The number of periods over which to compute the average range. |
Definition at line 35 of file AverageRange.cs.
| QuantConnect.Indicators.AverageRange.AverageRange | ( | int | period | ) |
Initializes the AR indicator with the default name format and period.
Definition at line 43 of file AverageRange.cs.
| override void QuantConnect.Indicators.AverageRange.Reset | ( | ) |
Resets the indicator and clears the internal state, including the SMA.
Definition at line 61 of file AverageRange.cs.
|
protected |
Computes the next value of the Average Range (AR) by calculating the price range (high - low) and passing it to the SMA to get the smoothed value.
| input | The input data for the current bar, including open, high, low, close values. |
Definition at line 73 of file AverageRange.cs.
| override bool QuantConnect.Indicators.AverageRange.IsReady => _sma.IsReady |
Indicates whether the indicator has enough data to start producing valid results.
Definition at line 51 of file AverageRange.cs.
| int QuantConnect.Indicators.AverageRange.WarmUpPeriod => _sma.WarmUpPeriod |
The number of periods needed to fully initialize the AR indicator.
Definition at line 56 of file AverageRange.cs.