Envelopes
interface cAlgo.API.Indicators
DesktopCLICloud
The Envelopes indicator is used to visualize potential trading ranges and overbought/oversold conditions.
Definition
public interface Envelopes
Namespace: cAlgo.API.Indicators · Group: Indicators · Implements: StandardIndicator
Examples
private Envelopes _envelopes;
protected override void OnStart()
{
_envelopes = Indicators.Envelopes(Bars.ClosePrices, 20, MovingAverageType.Simple, 0.1);
}
protected override void OnBar()
{
Print("Upper: {0}, Main: {1}, Lower: {2}", _envelopes.Upper.Last(1), _envelopes.Main.Last(1), _envelopes.Lower.Last(1));
}
def on_start(self):
self.envelopes = api.Indicators.Envelopes(api.Bars.ClosePrices, 20, MovingAverageType.Simple, 0.1)
def on_bar(self):
api.Print(f"Upper: {self.envelopes.Upper.Last(1)}, Main: {self.envelopes.Main.Last(1)}, Lower: {self.envelopes.Lower.Last(1)}")
Properties
| Name | Description |
|---|---|
LowerDesktopCLICloudIndicatorDataSeries | The lower line of the Envelopes. |
MainDesktopCLICloudIndicatorDataSeries | The main line of the Envelopes. |
UpperDesktopCLICloudIndicatorDataSeries | The upper line of the Envelopes. |
Inherited members
From StandardIndicator: AddToChart, Symbol, TimeFrame, Bars