Description
This is a Price Action Indicator, that helps you to identify the difference between trend / sideway market. Unlike Highest High Lowest Low indicator, here you don't need to set period. It adapts to the market, based on the logic of inside bars.
Buy, when price is above EMA and breaks up from the consolidation channel.
Sell, when price is below EMA and breaks down from the consolidation channel.
using System;
using cAlgo.API;
using cAlgo.API.Indicators;
namespace cAlgo.Indicators
{
[Indicator(IsOverlay = true)]
public class Break_Out_Channel : Indicator
{
//-----------------------------------------------------------------
[Output("Up", Color = Colors.DarkCyan, PlotType = PlotType.Line, LineStyle = LineStyle.LinesDots, Thickness = 1)]
public IndicatorDataSeries Up { get; set; }
[Output("Down", Color = Colors.DarkCyan, PlotType = PlotType.Line, LineStyle = LineStyle.LinesDots, Thickness = 1)]
public IndicatorDataSeries Down { get; set; }
[Output("Mid", Color = Colors.DarkViolet, PlotType = PlotType.Line, LineStyle = LineStyle.LinesDots, Thickness = 1)]
public IndicatorDataSeries Mid { get; set; }
//-----------------------------------------------------------------
public override void Calculate(int index)
{
if(index < 5)
return;
if(MarketSeries.Close[index] < Up[index-1] & MarketSeries.Close[index] > Down[index-1])
{
Up[index] = Up[index-1];
Down[index] = Down[index-1];
}
else
{
Up[index] = MarketSeries.High[index];
Down[index] = MarketSeries.Low[index];
}
Mid[index] = (Up[index] + Down[index])/2;
}
}
}
rkokerti
Joined on 28.06.2012
- Distribution: Free
- Language: C#
- Trading platform: cTrader Automate
- File name: Break_Out_Channel.algo
- Rating: 5
- Installs: 42378
- Modified: 13/10/2021 09:54
Comments
It works ok for me
Hi,
I don't know why source code disappeared, but I uploaded again.
Hi.
Can't download your indicator. I receive 404 error. Did You removed it.
Can You help me to get Your indicator Price Action / Break Out
Hi.
Can't download your indicator. I receive 404 error. Did You removed it.
Can You help me to get Your indicator Price Action / Break Out
Hi, I don't know how to install it. It says it's a .cs file and can't open it when I try to install it once downloaded.
thanks, Sylvie
Does not install on C-trader, likely file with problems, can solve?