StockFetcher Forums · Filter Exchange · Alpha Filter based on Ron Groenke Visions V<< 1 ... 5 6 7 8 9 >>Post Follow-up
nibor100
1,031 posts
msg #146691
Ignore nibor100
2/22/2019 4:28:20 PM

@SAFeTRADE,

I believe that the following group of lines from your latest filter don't always get you the 3 consecutive days up in price; but do always get you today's close is up in relation to each of those 3 days when each day is considered separately.

set{upa, count(close > close 1 day ago,1)}
set{upb, count(close > close 2 days ago,1)}
set{upc, count(close > close 3 dsys ago,1)}
set{upd, upa + upb}
set{up, upd + upc}

Ed S.

Cheese
1,374 posts
msg #146692
Ignore Cheese
2/22/2019 4:56:45 PM

Fetcher[
djia
set{upa, count(close > close 1 day ago,1)}
set{upb, count(close 1 day ago > close 2 days ago,1)}
set{upc, count(close 2 days ago > close 3 days ago,1)}
set{upd, upa + upb}
set{up, upd + upc}
up > 2
]



Cheese
1,374 posts
msg #146693
Ignore Cheese
modified
2/22/2019 5:11:35 PM

Fetcher[

/* SAFeTRADE modified 2/20/2019 12:48:18 PM with suggested changes */

/* all credits to SAFeTRADE modified 2/20/2019 12:48:18 PM with suggested changes */


set{clsaboveuab, count(close crossed above Upper Acceleration Band(30),1)}
set{cls, close}
set{52wklow, count(low reached a new 52 week low,1)}
set{20wklow, count(low reached a new 20 week low,1)}

set{fda50, close / ma(50)}
set{fda20, close / ma(20)} /* ************ suggested change typo corrected approved by SAFeTRADE */

set{fda50a, count(fda50 above .95,1) * count(fda50 below 1.05,1)}
set{fda,fda50a * 30}

set{fda20a, count(fda20 above .95,1) * count(fda20 below 1.05,1)}
set{fda2,fda20a * 30}

set{hl52, high 52 week high - low 52 week low}
set{blb, hl52 * .25}
set{bl, low 52 week low + blb}
set{buylimit,bl}

set{bra, bl - close}
set{brb, 10 * bra}
set{brc, brb / blb}

/*********************************************************************52 week****/


set{hl20, high 20 week high - low 20 week low}
set{blb2, hl20 * .50}
set{bl2, low 20 week low + blb2}
set{buylimit2,bl2}

set{bra2, bl2 - close}
set{brb2, 10 * bra2}
set{brc2, brb2 / blb2}


/*******************************************************************20week****/

/* Point 52 week low */

set{pointb1, bl * .125}
set{pointb, bl + pointb1}

set{pointc, low 52 week low + pointb1}
set{pntc, pointc}

/* Point20 20 week low */

set{pointb21, bl2 * .125}
set{pointb2, bl2 + pointb21}

set{pointc2, low 20 week low + pointb21}
set{pntc2, pointc2}

set{profit52, pointb / close}
set{profit20, pointb2 / close}



set{taa, ma(50) * 2}
set{tab, taa - close}
set{tac, ma(50) / tab }
set{tad, tac + 1}
set{tai, brc * tad}

set{taa2, ma(20) * 2}
set{tab2, taa2 - close}
set{tac2, ma(20) / tab2 }
set{tad2, tac2 + 1}
set{tai2, brc2 * tad2}

set{gr, count(tai above 10,1)}
set{ta, count(tai between -5 and 10,1)}
set{wait, count(tai between -10 and -4.9,1)}
set{bad_idea, count(tai below -10,1)}

set{gr2, count(tai2 above 10,1)}
set{ta2, count(tai2 between -5 and 10,1)}
set{wait2, count(tai2 between -10 and -4.9,1)}
set{bad_idea2, count(tai2 below -10,1)}


/* */

set{abvpc,count(close is above pointc,20)}

set{cabvpc, count(close > pointc,1)}
set{cblopb, count(close < pointb,1)}
set{in_zone, cabvpc * cblopb}

set{upa, count(close > close 1 day ago,1)}
set{upb, count(close 1 day ago > close 2 days ago,1)} /* *************** suggested changes */
set{upc, count(close 2 days ago > close 3 days ago,1)} /* ************** suggested changes */
set{upd, upa + upb}
set{up, upd + upc}
up > 2 /* *********** suggested changes only if you want 3 days up */


set{g2, up * 3.334}/*days up * 10*/

set{g3, in_zone * 30}/* within Pointb and pointc * 30 will be either 0 or 30*/
set{g3a, fda * 2}
set{g4, g2+g3}

set{g5, g3a + g4}/* 10 * Number of days up + 2 * Number of days between pointb and pointc */

/* */

set{abvpc2,count(close is above pointc2,20)}

set{cabvpc2, count(close > pointc2,1)}
set{cblopb2, count(close < pointb2,1)}
set{in_zone2, cabvpc2 * cblopb2}

set{upa2, count(close > close 1 day ago,1)}
set{upb2, count(close 1 day ago > close 2 days ago,1)} /* *************** suggested changes */
set{upc2, count(close 2 days ago > close 3 days ago,1)} /* ************** suggested changes */
set{upd2, upa2 + upb2}
set{up2, upd2 + upc2}
up2 > 2 /* *********** suggested changes only if you want 3 days up */

set{g22, up * 3.334}/*days up * 10*/

set{g32, in_zone * 30}/* within Pointb and pointc * 30 will be either 0 or 30*/
set{g32a, fda * 2}
set{g42, g2+g3}

set{g52, g3a + g4}/* 10 * Number of days up + 2 * Number of days between pointb and pointc */

/***************************************************************************************************/
/********************* Start Universe of Stocks*****************************************************/
/***************************************************************************************************/
dow 30
market_cap above 1000
not otcbb
close above 5
volume above 500000
/*close below buylimit
close above pntc
do not draw pntc
do not draw buylimit*/
/*close below buylimit2
close above pntc2
do not draw pntc2
do not draw buylimit2*/

/***************************************************************************************************/
/********************* End Universe of Stocks*******************************************************/
/***************************************************************************************************/



add column gr
add column ta
/*add column wait
add column bad_idea*/
add column separator
add column gr2
add column ta2
/*add column wait2
add column bad_idea2*/
add column separator

/*add column up{days_up52}*/
/*add column g22
add column g32
add column g42
add column g4a2*/
add column g5{gold52}
add column separator
/*add column up2{days_up20}*/
add column g52{gold20}




draw bl on plot price
draw bl2 on plot price
draw pointc on plot price
draw pointc2 on plot price
draw ma(50)
draw ma(20)
add column separator
/*add column up{days_up}
add column g2{daysup*10}
add column g3{between_b_andC_=30}*/
/* add column g3
add column g4{inrange 50}*/
add column fda*/
/*add column g4a{number_of_days_*2}*/
add column g5{Gold}

draw 52wklow
draw 20wklow


draw tai line at 10
draw tai line at -5
draw tai2 line at 10
draw tai2 line at 5

add column brc{Rank52}
add column brc2{rank20}


add column tai{tai52}
add column tai2{tai20}

/*add column bl
add column bl2*/
add column separator
add column pointc{stop52}
add column pointb{profit52}
add column profit52{profit%52}
add column separator
add column pointc2{stop20}
add column pointb2{profit20}
add column profit20{profit%20}
add column in_zone{within_b&c50}
add column in_zone2{within_b&c20}
add column clsaboveuab
add column market_cap
/*draw low 52 week low
draw low 20 week low*/

draw fda50 line at .95
draw fda50 line at 1.05

draw fda20 line at .95
draw fda20 line at 1.05

draw Williams %R(30)
draw cci(30) line at 100
draw cci(30) line at -100
draw Upper Acceleration Band(30) on plot cls
draw clsaboveuab

chart-length 6 months
]




Cheese
1,374 posts
msg #146694
Ignore Cheese
2/22/2019 5:25:09 PM

Thank you, Ed S nibor100 and SAFeTRADE,
For everyone's convenience, I've coded the suggested changes,
subject to SAFeTRADE's concurrence.

SAFeTRADE
644 posts
msg #146695
Ignore SAFeTRADE
2/22/2019 5:53:14 PM

Ed S thanks for picking that up, I missed that and Cheese for editing it out and putting in the correct code.

Much appreciated.

Safetrade

SAFeTRADE
644 posts
msg #146756
Ignore SAFeTRADE
2/28/2019 3:28:50 PM

Image and video hosting by TinyPic

Would one or more of the math wizards on this site check my coding and math to see if I have coded
this correctly.

Fetcher[
set{fdal, ma(50) * .95}
set{fdah, ma(50) * 1.05}
set{zz, count(close above fdah,1)}
set{xx, count(zz > 0,1)}
set{adays252, count(xx above 0,252)}
set{adays20, count(xx above 0,20)}

set{fdays, 20}
set{tdays, 252}

/*********POF1**********/

set{x, tdays - fdays}
set{x2, x / tdays}

set{y, adays252 / fdays}
set{y2, x2 * y}
set{pofa1, y2 *1}

/*********POF2*****/

set{b, fdays / tdays}
set{b2, tdays - fdays}
set{b3, adays20 / b2}
set{pofa2, b * b3}

set{pofa, pofa1 * pofa2}



s&p 500

add column pofa
add column pofa1
add column pofa2





add column adays252/*traded above ma50 + .05 in a year*/
add column adays20/*traded above ma50 + .05 in the last 20 days*/
add column roc(13,1)
draw ma(50)
chart-length 1 year
]



This a performance of price achievement piece for the Visions V filter. Also called a Odds Enhancer.

I will be posting an updated filter at some point.

Safetrade

jimvin
173 posts
msg #146768
Ignore jimvin
3/1/2019 11:20:00 AM

My compliments Cheese.

Copying your code into a spreadsheet, then reducing all double- and triple-spaces to single lines, I believe you've topped TRO as creating the longest filter on Stockfetcher, clocking in at a whopping 229 lines.



Cheese
1,374 posts
msg #146770
Ignore Cheese
modified
3/1/2019 11:54:01 AM

Thank you, jimvin, but I've only done minimal editing to SAFeTRADE's code
All the credits for the GROENKE stuff that counts in this thread
should go to SAFeTRADE, nibor100 & snappyfrog

My personal filters are more like four, very few lines of code, very few lines of chart
most of the time.

Here's my own all-time favorite:
https://www.stockfetcher.com/forums/Filter-Exchange/You-re-favorite-intraday-indicators/39216&isiframe=
Credits for the ideas go to BFreshour, TRO, and WSG riggs

Fetcher[
draw Fisher Transform(10) line at 0
draw rsi(5)
draw cci(14)
draw adx(5)
draw ema(13)
add column Fisher Transform(10) {FT10}
symlist(SSO,SDS)
]



nibor100
1,031 posts
msg #146775
Ignore nibor100
3/1/2019 4:26:05 PM

a 2 line version:

Fetcher[
symlist(SSO,SDS) draw Fisher Transform(10) line at 0 draw rsi(5) draw cci(14) draw adx(5) draw ema(13)
add column Fisher Transform(10) {FT10}
]



Ed S.

Cheese
1,374 posts
msg #146776
Ignore Cheese
3/1/2019 9:04:09 PM

nibor100 3/1/2019 4:26:05 PM
a 2 line version:
==============================

Mine looks a lot clearer ,^)


StockFetcher Forums · Filter Exchange · Alpha Filter based on Ron Groenke Visions V<< 1 ... 5 6 7 8 9 >>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.