StockFetcher Forums · Filter Exchange · A half-assed breakout filter (WIP)<< >>Post Follow-up
graftonian
1,089 posts
msg #155163
Ignore graftonian
12/31/2020 8:12:55 PM

Fetcher[
/* trendsum code by Kevin_in_GA */
/*TRENDSUM*/
not OTCBB
optionable
Average Volume(30) > 500000
close > .50
/*1. IS THE MA(3) ABOVE THE MA(6)? +1 FOR YES, -1 FOR NO*/
set{var1a, count(ma(3) above ma(6), 1)}
set{var1b, count(ma(3) below ma(6), 1)}
set{var1, var1a - var1b}

/*2. IS THE CLOSE ABOVE THE MA(3)? +1 FOR YES, -1 FOR NO*/
set{var2a, count(close above ma(3), 1)}
set{var2b, count(close below ma(3), 1)}
set{var2, var2a - var2b}

/*3. IS THE CLOSE ABOVE THE MA(6)? +1 FOR YES, -1 FOR NO*/
set{var3a, count(close above ma(6), 1)}
set{var3b, count(close below ma(6), 1)}
set{var3, var3a - var3b}

/*4. IS THE SLOPE OF MA(3) POSITIVE? +1 FOR YES, -1 FOR NO*/
set{var4a, count(ma(3) above ma(3) 1 day ago, 1)}
set{var4b, count(ma(3) below ma(3) 1 day ago, 1)}
set{var4, var4a - var4b}

/*5. IS THE SLOPE OF MA(6) POSITIVE? +1 FOR YES, -1 FOR NO*/
set{var5a, count(ma(6) above ma(6) 1 day ago, 1)}
set{var5b, count(ma(6) below ma(6) 1 day ago, 1)}
set{var5, var5a - var5b}

/*6. IS THE CLOSE ABOVE THE PARABOLIC SAR? +1 FOR YES, -1 FOR NO*/
set{var6a, count(close above Parabolic SAR(0.02,0.2), 1)}
set{var6b, count(close below Parabolic SAR(0.02,0.2), 1)}
set{var6, var6a - var6b}

/*7. IS THE +DI(14) ABOVE THE -DI(14)? +1 FOR YES, -1 FOR NO*/
set{var7a, count(PDI above MDI, 1)}
set{var7b, count(PDI below MDI, 1)}
set{var7, var7a - var7b}

/*SUMMING THE INDIVIDUAL INDICATORS INTO THE TRENDSUM*/
set{sum1, var1 + var2}
set{sum2, sum1 + var3}
set{sum3, sum2 + var4}
set{sum4, sum3 + var5}
set{sum5, sum4 + var6}
set{trendsum, sum5 + var7}
set{TrendSumAvg, cema(trendsum, 6)}
ADD COLUMN TRENDSUM
DRAW MA(3)
DRAW MA(6)
DRAW PARABOLIC SAR
DRAW TRENDSUMavg
PLOTTYPE{TRENDSUMavg, ZEROBAR}
/*trend days*/
set{TrendDays, days(trendsum < 1, 20)}
add column TrendDays and sort on column 6 descending
TrendDays > 0
do not draw TrendDays
/* add PSAR resriction */
close > Parabolic SAR(0.02,0.2)
/* add squeeze restrictions */
Upper Bollinger Band(20,2) < Upper Keltner Band(10,1.0)
Lower Bollinger Band(20,2) > Lower Keltner Band(10,1.0)
]



StockFetcher Forums · Filter Exchange · A half-assed breakout filter (WIP)<< >>Post Follow-up

*** Disclaimer *** StockFetcher.com does not endorse or suggest any of the securities which are returned in any of the searches or filters. They are provided purely for informational and research purposes. StockFetcher.com does not recommend particular securities. StockFetcher.com, Vestyl Software, L.L.C. and involved content providers shall not be liable for any errors or delays in the content, or for any actions taken based on the content.


Copyright 2022 - Vestyl Software L.L.C.Terms of Service | License | Questions or comments? Contact Us
EOD Data sources: DDFPlus & CSI Data Quotes delayed during active market hours. Delay times are at least 15 mins for NASDAQ, 20 mins for NYSE and Amex. Delayed intraday data provided by DDFPlus


This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.