Here is a simple screener to find both Evening Star and Morning Star candlestick patterns.
The screener returns a signal named “Go”, which can be:
1 = Go long (Morning Star found)
-1 = Go Short (Evening Star found)
A variable named “BaseCandle” represents the first pattern candle from the right, so a search for past patterns can be done.
To the known 3 candles pattern, I added one more black candle to the Morning Star to check previous trend. In the same way, to the Evening Star I added one more white candle.
//BaseCandle parameter = first candle of the pattern, starting from right (it is possible to run screener staring from any past candle)
BaseCandle = 0
Open0 = Open[BaseCandle]
Close0 = Close[BaseCandle]
Open1 = Open[BaseCandle + 1]
Close1 = Close[BaseCandle + 1]
Open2 = Open[BaseCandle + 2]
Close2 = Close[BaseCandle + 2]
Open3 = Open[BaseCandle + 3]
Close3 = Close[BaseCandle + 3]
EvStar = Open0 > Close0 And Open0 < Close1 And Open1 > Close1 And Close1 > Close2 And Open2 < Close2 And Close2 > Close3 And Open3 < Close3
MornStar = Open0 < Close0 And Open0 > Close1 And Open1 < Close1 And Close1 < Close2 And Open2 > Close2 And Close2 < Close3 And Open3 > Close3
//Go Short Signal = -1
If EvStar then
Go = -1
//Go Long Signal = 1
If MornStar then
Go = 1
Condition = (EvStar Or MornStar)
SCREENER[Condition] (Go AS "Go")
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.ProRealTime ITF files and other attachments :
PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials
Nice screener but the 2 candelsticks around the doji should be long sticks (red and green). Furthermore, there should ideally be a gap between the 2 long candelsticks and the doji.