Description
Comes with source code.
This is a custom building block for handling signals generated by an Oscillator.
Similarly to IndiCrossover it takes DataSeries as inputs (one for the Oscillator series, one for a high band and one for a low band).
For instance, on EURUSD Daily, we have used it to manage close price breakouts from the Bollinger Bands in red. We have also used it on the Williams %R using -20 and -80 levels generated using the LevelSeries building block.
Outputs:
- Signal: 1 on the bar where the Oscillator crosses above or below one of the two levels (high or low), 0 otherwise.
- SignalEnv: 1 if the Oscillator is above the high-band, -1 if below the low-band, 0 otherwise.
- DaysSinceLastSignal: The number of bars since the Signal was last 1.
using System;
using cAlgo.API;
using cAlgo.API.Internals;
using cAlgo.API.Indicators;
using cAlgo.Indicators;
namespace cAlgo
{
[Indicator(IsOverlay = true, TimeZone = TimeZones.UTC, AccessRights = AccessRights.None)]
public class DirectIndiOscillator : Indicator
{
protected override void Initialize()
{
// *** Requires no access rights ***
// Available at: https://fxtradersystems.com/product/indioscillator/
}
public override void Calculate(int index)
{
Chart.DrawStaticText("Availiability", "Visit: https://fxtradersystems.com/product/indioscillator/", VerticalAlignment.Bottom, HorizontalAlignment.Left, Color.LawnGreen);
}
}
}
fxtradersystems
Joined on 10.09.2020
- Distribution: Free
- Language: C#
- Trading platform: cTrader Automate
- File name: DirectIndiOscillator.algo
- Rating: 0
- Installs: 1355
- Modified: 13/10/2021 09:54
Note that publishing copyrighted material is strictly prohibited. If you believe there is copyrighted material in this section, please use the Copyright Infringement Notification form to submit a claim.
Comments
Log in to add a comment.
No comments found.