This screener code will detect price breakout / reversal over round numbers (or “sweet spots”).
They are 2 different levels that the screener can detect, the Main and the Sub ones. You can change them in the code between settings lines.
The screener is made of this indicator: Sweet Spots & round numbers
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 |
//PRC_RoundNumber touch Screener | screener //30.03.2018 //Nicolas @ www.prorealcode.com //Sharing ProRealTime knowledge // --- settings MainLevels = 100 SubLevels = 50 // --- end of settings DecAr = MainLevels*pointsize DecArSub = SubLevels*pointsize myVarUp = close myVarDn = close myVarUpSub = close myVarDnSub = close if DecAr = 0 then InvDec = 1 else InvDec = 1/DecAr endif if DecArSub = 0 then InvDecSub = 1 else InvDecSub = 1/DecArSub endif Floor = round(InvDec*myVarDn-0.51)/InvDec Ceil = round(InvDec*myVarUp+0.51)/InvDec FloorSub = round(InvDecSub*myVarDnSub-0.51)/InvDecSub CeilSub = round(InvDecSub*myVarUpSub+0.51)/InvDecSub myVarUp=Ceil myVarDn=Floor myVarUpSub=CeilSub myVarDnSub=FloorSub crossover = close crosses over myVarUp[1] or close crosses over myVardn[1] or close crosses over myvarupsub[1] or close crosses over myvardnsub[1] crossunder = close crosses under myVarUp[1] or close crosses under myVardn[1] or close crosses under myvarupsub[1] or close crosses under myvardnsub[1] test = crossover or crossunder screener[test] |
Share this
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 :
Filename : download the ITF files
How to import ITF files into ProRealTime platform?
PRC is also on YouTube, subscribe to our channel for exclusive content and tutorials
Is it possible to have fibo numbers like 1, 2, 3, 5,8 sequence by modifying the calculation?
sorry i dont get it. you want to plot the next level at current price + ratio?
I meant not plotting 4, 6 and 7. This question about having 1,3,5,8 sequence was meant to be in indicator section. If possible.
I wanted to see if plotting this is possible:
Plot 1 and 2 numbers, add 1+2=3, then add 2+3=5, then 3+5=8