#TheStrat Candles

Category: Indicators By: juanj Created: January 12, 2021, 4:45 PM
January 12, 2021, 4:45 PM
Indicators
5 Comments

This indicator follows on the previous #TheStrat indicators which compliment the work of @RobInTheBlack (Twitter Handle) who has helped countless traders with this pure price action based strategy that he developed over the past 27 years of trading, It is called #TheStrat

This indicator will number the different candle types as mentioned here: https://www.newtraderu.com/2019/02/13/what-do-we-know-to-be-true-about-price-action/

The Moving Average period in the configuration is used to determine which side of the candle the 1 and 3 candles are displayed.

I recommend importing the .ITF in order to load the variables, but for those interested here is the code:

//Spacing = 3
//Tollerance = 0
//MovingAverage = 40

InsideBar = high < high[1]-tollerance*pointsize and low > low[1]+tollerance*pointsize
OutsideBar = high > high[1]+tollerance*pointsize and low < low[1]-tollerance*pointsize

TwoUp = high > high[1]+tollerance*pointsize and low > low[1]+tollerance*pointsize
TwoDown = low < low[1]-tollerance*pointsize and high < high[1]-tollerance*pointsize

Up = close > open+tollerance*pointsize
Down = close < Open-tollerance*pointsize

If TwoUp Then
 drawtext("2↑",barindex,low-spacing*pointsize,dialog,standard,12) coloured(0,255,0)
 ElsIf TwoDown Then
  drawtext("2↓",barindex,high+spacing*pointsize,dialog,standard,12) coloured(255,0,0)
 ElsIf InsideBar Then
  If low > Average[MovingAverage](close) Then
   drawtext("1",barindex,low-spacing*pointsize,dialog,standard,12) coloured(255,165,0)
  Else
   drawtext("1",barindex,high+spacing*pointsize,dialog,standard,12) coloured(255,165,0)
  EndIf
 ElsIf OutsideBar Then
  If low > Average[MovingAverage](close) Then
   drawtext("3",barindex,low-spacing*pointsize,dialog,standard,12) coloured(0,0,255)
  Else
   drawtext("3",barindex,high+spacing*pointsize,dialog,standard,12) coloured(0,0,255)
  EndIf
EndIf

Return

 

Download
Filename: The-Strat-Candles.itf
Downloads: 428
juanj Master
My name is Juan Jacobs and I am an algorithmic trader and trading coach. After 7 years of corporate work as a Systems Analyst, I have decided to pursue my passion of trading on a full-time basis. My current focus area is that of 'smart' strategies based on 'Machine Learning'. You can find me at www.FXautomate.com or visit my PRC Marketplace Store here: https://market.prorealcode.com/store/fxautomate/
Author’s Profile

Comments

Logo Logo
Loading...