Screener Range filter
Forums › ProRealTime forum Français › Support ProScreener › Screener Range filter
- This topic has 2 replies, 2 voices, and was last updated 3 years ago by PRC_2021.
Viewing 3 posts - 1 through 3 (of 3 total)
-
-
01/04/2021 at 9:33 PM #156351
Bonjour,
J’essaie depuis un moment de convertir l’indicateur “Range Filter” en screener qui sélectionnera les actions passant du rouge au vert avec un minimum de volume échangé de 30 000 actions.
J’ai un compte fin de journée et non en temps réel.
Pour rappel, voici le code de l’indicateur
PRC_Range Filter123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129//PRC_Range Filter | indicator//06.10.2020//Nicolas @ www.prorealcode.com//Sharing ProRealTime knowledge// --- settingsftype = 1 //Filter Type (1 or 2?)rngqty = 2.618 //Range Sizerngscale = 6 //Range Scale (1=Points, 2=Pips, 3=Ticks, 4=% of Price, 5=ATR, 6=Average Change, 7=Standard Deviationrngper = 14 //Range Period (for ATR, Average Change, and Standard Deviation)smoothrange = 1 //Smooth Range (0=false ; 1=true)smoothper = 27 //Smoothing Periodmovsrc = 1 //Movement Source (0=Wicks, 1=Close)//--- end of settingsonce rngfilt=closeif barindex>max(rngper,smoothper) then//Range Size Functionrngscale=max(1,min(rngscale,7))if rngscale=1 thenscale = rngqty*pointsizeelsif rngscale=2 thenscale = rngqty*.0001elsif rngscale=3 thenscale = rngqty*ticksizeelsif rngscale=4 thenscale = close*rngqty/100elsif rngscale=5 thenscale = rngqty*average[rngper,1](tr)elsif rngscale=6 thenscale = rngqty*average[rngper,1](abs(close-close[1]))elsif rngscale=7 thenscale = STD[rngper](close)endifif smoothrange thenr=average[smoothper,1](scale)elser=scaleendifhh=closell=closeif movsrc<>1 thenhh=highll=lowendifif ftype=1 thenif hh>rngfilt[1] thenif (hh-r)<rngfilt[1] thenrngfilt=rngfilt[1]elserngfilt=hh-rendifelsif (ll+r)>rngfilt[1] thenrngfilt=rngfilt[1]elserngfilt=ll+rendifelse //ftype<>1if hh>=rngfilt[1]+r thenrngfilt=(rngfilt[1]) + floor(abs(hh - (rngfilt[1]))/r)*relsif ll<=rngfilt[1]-r thenrngfilt=(rngfilt[1]) - floor(abs(ll - (rngfilt[1]))/r)*relserngfilt=rngfilt[1]endifendifhiband = rngfilt + rloband = rngfilt - rif rngfilt>rngfilt[1] thenupward=1downward=0endifif rngfilt<rngfilt[1] thenupward=0downward=1endif//Direction Conditions & colorsif upward thencr=5cg=255cb=155endifif downward thencr=255cg=5cb=131endifif (close > rngfilt) and (close > (close[1])) and (upward > 0) thenbr=5bg=255bb=155//#05ff9belsif (close > rngfilt) and (close <= (close[1])) and (upward > 0) thenbr=0bg=179bb=107//#00b36belsif (close < rngfilt) and (close < (close[1])) and (downward > 0) thenbr=255bg=5bb=131//#ff0583elsif (close < rngfilt) and (close >= (close[1])) and (downward > 0) thenbr=184bg=0bb=93//#b8005delsebr=204bg=204bb=204endifdrawcandle(open,high,low,close) coloured(br,bg,bb) bordercolor(0,0,0)//Band Fillsdrawtriangle(barindex[1],hiband[1],barindex,rngfilt,barindex[0],hiband[0]) coloured(0,179,107,85) bordercolor(0,179,107,0)drawtriangle(barindex[1],hiband[1],barindex[1],rngfilt[1],barindex[0],rngfilt[0]) coloured(0,179,107,85) bordercolor(0,179,107,0)drawtriangle(barindex[1],loband[1],barindex,rngfilt,barindex[0],loband[0]) coloured(184,0,93,85) bordercolor(184,0,93,0)drawtriangle(barindex[1],loband[1],barindex[1],rngfilt[1],barindex[0],rngfilt[0]) coloured(184,0,93,85) bordercolor(184,0,93,0)endifreturn rngfilt coloured(cr,cg,cb) style(line,3) as "Filter"Merci pour votre aide.
Manu
01/05/2021 at 9:46 AM #156392Tu trouveras ci-dessous le screener pour cet indicateur le range filter. Il détecte le passage du rouge au vert.
1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980//PRC_Range Filter | screener//06.10.2020//Nicolas @ www.prorealcode.com//Sharing ProRealTime knowledge// --- settingsftype = 1 //Filter Type (1 or 2?)rngqty = 2.618 //Range Sizerngscale = 6 //Range Scale (1=Points, 2=Pips, 3=Ticks, 4=% of Price, 5=ATR, 6=Average Change, 7=Standard Deviationrngper = 14 //Range Period (for ATR, Average Change, and Standard Deviation)smoothrange = 1 //Smooth Range (0=false ; 1=true)smoothper = 27 //Smoothing Periodmovsrc = 1 //Movement Source (0=Wicks, 1=Close)//--- end of settingsonce rngfilt=closeif barindex>max(rngper,smoothper) then//Range Size Functionrngscale=max(1,min(rngscale,7))if rngscale=1 thenscale = rngqty*pointsizeelsif rngscale=2 thenscale = rngqty*.0001elsif rngscale=3 thenscale = rngqty*ticksizeelsif rngscale=4 thenscale = close*rngqty/100elsif rngscale=5 thenscale = rngqty*average[rngper,1](tr)elsif rngscale=6 thenscale = rngqty*average[rngper,1](abs(close-close[1]))elsif rngscale=7 thenscale = STD[rngper](close)endifif smoothrange thenr=average[smoothper,1](scale)elser=scaleendifhh=closell=closeif movsrc<>1 thenhh=highll=lowendifif ftype=1 thenif hh>rngfilt[1] thenif (hh-r)<rngfilt[1] thenrngfilt=rngfilt[1]elserngfilt=hh-rendifelsif (ll+r)>rngfilt[1] thenrngfilt=rngfilt[1]elserngfilt=ll+rendifelse //ftype<>1if hh>=rngfilt[1]+r thenrngfilt=(rngfilt[1]) + floor(abs(hh - (rngfilt[1]))/r)*relsif ll<=rngfilt[1]-r thenrngfilt=(rngfilt[1]) - floor(abs(ll - (rngfilt[1]))/r)*relserngfilt=rngfilt[1]endifendifif rngfilt>rngfilt[1] thenupward=1endifif rngfilt<rngfilt[1] thenupward=0endifendiftest = upward and not upward[1] and volume>30000screener[test]1 user thanked author for this post.
01/05/2021 at 10:51 AM #156406 -
AuthorPosts
Viewing 3 posts - 1 through 3 (of 3 total)
Find exclusive trading pro-tools on
Similar topics: