Crosses multiple indicators over 10 periods
- This topic has 5 replies, 2 voices, and was last updated 5 years ago by .
Viewing 6 posts - 1 through 6 (of 6 total)
Viewing 6 posts - 1 through 6 (of 6 total)
Similar topics:
Forums › ProRealTime English forum › ProScreener support › Crosses multiple indicators over 10 periods
Hi,
Im looking to create a screener than gives me results when the upper BolBand, Lower BolBand and Moving Average have been crossed in that order over the last 10 bars.
The result doesnt seem to want to execute. Thanks. I have just put in the // so the code can been seen.
1 2 3 4 5 6 7 8 9 10 11 |
timeframe(30mn) Bol5 = (BollingerUp[15](close)) boldown = (BollingerDown[15](close)) movingA = average[15] c1= high crosses over bol5 c2= low crosses under boldown c3= close crosses over movingA //result= summation[10](c1 then c2 then c3) screener [result] |
Try this (not tested):
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
timeframe(30mn) Bol5 = (BollingerUp[15](close)) boldown = (BollingerDown[15](close)) movingA = average[15] c1= high crosses over bol5 if c1 then bar1 = barindex //it must have the lowest barindex endif c2= low crosses under boldown if c2 then bar2 = barindex endif c3= close crosses over movingA if c3 then bar3 = barindex //it must have the highest barindex endif // MaxBar = (c3 = max(bar1,max(bar2,bar3))) MinBar = (c1 = min(bar1,min(bar2,bar3))) result = MaxBar AND MinBar AND ((BarIndex - bar1) <= 10) screener [result] |
Do not double post. Ask your question only once and only in one forum. All double posts will be deleted anyway so posting the same question multiple times will just be wasting your own time and will not get you an answer any quicker. Double posting just creates confusion in the forums.
Thank you 🙂
I deleted the other topic.
I dont seem to be getting any hits with the above code on Australian stocks considering i can see there are a few companies in their last 10 (30min) bars have all 3 definitions meet. I even tried to stretch it further (15 bars) out to have a bigger possible pool and no luck.
Try writing (30 minute) at line 1.
Sorry, my fault, lines 18 and 19 are wrong. This is correct:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
timeframe(30mn) Bol5 = (BollingerUp[15](close)) boldown = (BollingerDown[15](close)) movingA = average[15] c1= high crosses over bol5 if c1 then bar1 = barindex //it must have the lowest barindex endif c2= low crosses under boldown if c2 then bar2 = barindex endif c3= close crosses over movingA if c3 then bar3 = barindex //it must have the highest barindex endif // MaxBar = (bar3 = max(bar1,max(bar2,bar3))) MinBar = (bar1 = min(bar1,min(bar2,bar3))) result = MaxBar AND MinBar AND ((BarIndex - bar1) <= 10) screener [result] |
Find exclusive trading pro-tools on