Incorrect ENGULFING ?
Forums › ProRealTime English forum › ProScreener support › Incorrect ENGULFING ?
- This topic has 9 replies, 2 voices, and was last updated 6 years ago by robertogozzi.
-
-
03/14/2018 at 12:16 PM #65284
I am having troubles with my proscreener to detect engulfing patterns on a Daily chart (I did not test other TFs, so far).
ProScreener sometimes reports incorrect results.
This is my code:
123456789101112131415ONCE BodySize = 10 * pipsize //Body is required to be at least 10 pips largeEngulf = 0 //Variable used for criterionBody = abs(open - close) //This is the BODY of the candleBearish = open > close //BEARish candleBullish = open < close //BULLish candleIF Bearish[1] THEN //Previous candle was BEARishIF open <= close[1] AND close >= open[1] AND Bullish THEN // this candle's Open must be <= previous Close AND Close >= previous Open AND must be BullishEngulf = (Body > Body[1]) AND (Body >= BodySize) // this candle's Body > than previous one AND >= desired sizeENDIFELSIF Bullish[1] THEN //Previous candle was BULLishIF open >= close[1] AND close <= open[1] AND Bearish THEN // this candle's Open must be >= previous Close AND Close <= previous Open AND must be BearishEngulf = (Body > Body[1]) AND (Body >= BodySize) // this candle's Body > than previous one AND >= desired sizeENDIFENDIFSCREENER[Engulf]I tried so many time to study my code, but can’t find any logic error. An engulfing pattern must have a greater body, no gaps (unless they are part of the engulfing itself) and going the other way round.
I attach a screensot of current Aud/Jpy daily chart.
03/21/2018 at 3:02 AM #65916I also tested it on Eur/Cad, h4, still working incorrectly.
Oddly enough, most of the times it works finely on Daily, h4 and h1 TFs. Can’t figure out what may cause this behaviour occasionally.
I tried to remove ONCE in line 1, but the output doesn’t change.
03/21/2018 at 10:47 AM #65954Have no results in Forex pairs right now, but all good ones on the Euronext shares list though, daily timeframe. I do not see any problem in your code. Do the problem exist on ‘predefined list’ too? I see you are using personalized ones.. (just in case..).
03/21/2018 at 10:55 AM #65957Yes, I just found Eur/Mxn, h4. It’s not an engulfing pattern!
03/21/2018 at 11:20 AM #65966These are all I found in “currencies” list, 4 hours timeframe. All goods for me. No EUR/MXN. I’m with PRT-CFD.
1 user thanked author for this post.
03/21/2018 at 11:35 AM #65974At present I can’t find other incorrect pairs.
Thank you Nicolas!
03/21/2018 at 3:07 PM #65991Sorry Nicolas, I just found another pair, NzdJpy, h4.
03/21/2018 at 3:10 PM #65993Now another one, AudUsd, h4.
03/22/2018 at 9:37 AM #66052Since I can’t replicate the problem with my own personal account @ PRT-CFD, I suggest:
_ compare every variable value with the one on the chart by using the sorting criteria : SCREENER [engulfing] (myvariable)
_ open a new support ticket …
1 user thanked author for this post.
03/22/2018 at 10:44 AM #66067Thank you Nicolas, I appreciated!
-
AuthorPosts