StockFetcher Forums · Filter Exchange · Help with filter<< >>Post Follow-up
T_Charp13
30 posts
msg #159453
Ignore T_Charp13
8/13/2022 10:59:36 AM

Hi all,

Can someone help me out with a filter. I need the numbers in the columns from the filter below to display the weekly numbers. It's currently showing the daily numbers but need to change those since it's a "chart-display is weekly". Much appreciated, thanks.

Fetcher[
apply to symlist(spy, qqq, smh, xbi, uvxy, xlf)
chart-display is weekly
set{E1352b,days(ma(2) is above dma(2,-1),100)}
set{E1352a,days(ma(2) is below ma(2,-1),100)}
set{M13xM52, E1352a - E1352b}

set{D1352, ma(2) - dma(2,-1)}
draw D1352 line 0

set{E3,ma(2)-DMA(2,-1) }
set{Shortposition, count(E3 > 0,1)}
set{Longposition, count(E3 < 0,1)}
SET{TRIGGER,0}
draw Shortposition on plot
draw Longposition on plot

set{E1351b,days(ma(5) is above dma(5,-3),100)}
set{E1351a,days(ma(5) is below ma(5,-3),100)}
set{M13xM51, E1351a - E1351b}

set{D1351, ma(5) - dma(5,-3)}

draw MA(2)
draw DMA(2,-1)

draw D1351 line 0

set{E4,ma(5)-DMA(5,-3) }
set{Shortposition1, count(E4 > 0,1)}
set{Longposition1, count(E4 < 0,1)}
SET{TRIGGER1,0}
draw Shortposition1 on plot
draw Longposition1 on plot

set{E1353b,days(ma(10) is above dma(10,-5),100)}
set{E1353a,days(ma(10) is below ma(10,-5),100)}
set{M13xM53, E1353a - E1353b}

set{D1353, ma(10) - dma(10,-5)}

draw D1353 line 0

set{E5,ma(10)-DMA(10,-5) }
set{Shortposition2, count(E5 > 0,1)}
set{Longposition2, count(E5 < 0,1)}
SET{TRIGGER2,0}
draw Shortposition2 on plot
draw Longposition2 on plot

add column D1352 {MA(2) -long +short}
add column D1351 {MA(5) -long +short}
add column D1353 {MA(10) -long +short}
]



KSK8
545 posts
msg #159454
Ignore KSK8
8/13/2022 12:45:33 PM

Hope this is it, just required inserting weekly before the indicators

Fetcher[

apply to symlist(spy, qqq, smh, xbi, uvxy, xlf)
chart-display is weekly
set{E1352b,days(weekly ma(2) is above weekly dma(2,-1),100)}
set{E1352a,days(weekly ma(2) is below weekly ma(2,-1),100)}
set{M13xM52, E1352a - E1352b}

set{D1352, weekly ma(2) - weekly dma(2,-1)}
draw D1352 line 0

set{E3,weekly ma(2)- weekly DMA(2,-1) }
set{Shortposition, count(E3 > 0,1)}
set{Longposition, count(E3 < 0,1)}
SET{TRIGGER,0}
draw Shortposition on plot
draw Longposition on plot

set{E1351b,days(weekly ma(5) is above weekly dma(5,-3),100)}
set{E1351a,days(weekly ma(5) is below weekly ma(5,-3),100)}
set{M13xM51, E1351a - E1351b}

set{D1351, weekly ma(5) - weekly dma(5,-3)}

draw weekly MA(2)
draw weekly DMA(2,-1)

draw D1351 line 0

set{E4,ma(5)-DMA(5,-3) }
set{Shortposition1, count(E4 > 0,1)}
set{Longposition1, count(E4 < 0,1)}
SET{TRIGGER1,0}
draw Shortposition1 on plot
draw Longposition1 on plot

set{E1353b,days(weekly ma(10) is above weekly dma(10,-5),100)}
set{E1353a,days(weekly ma(10) is below weekly ma(10,-5),100)}
set{M13xM53, E1353a - E1353b}

set{D1353, weekly ma(10) - weekly dma(10,-5)}

draw D1353 line 0

set{E5,weekly ma(10)- weekly DMA(10,-5) }
set{Shortposition2, count(E5 > 0,1)}
set{Longposition2, count(E5 < 0,1)}
SET{TRIGGER2,0}
draw Shortposition2 on plot
draw Longposition2 on plot

add column D1352 {weekly MA(2) -long +short}
add column D1351 {weekly MA(5) -long +short}
add column D1353 {weekly MA(10) -long +short}

]



Best of luck, rarely ever see ma(2) used so that's interesting

T_Charp13
30 posts
msg #159456
Ignore T_Charp13
8/13/2022 12:58:19 PM

Perfect, thank you so much! I was putting the "weekly" in the wrong spot and I wasn't using the parens. Yeah, the ma(2) is for super short term signals but it has been working.

dtatu
134 posts
msg #159460
Ignore dtatu
modified
8/14/2022 8:15:28 PM

(modified)
I'm trying to test it and having a problem: the short/long on the plot seem to be excellent timing-wise, but , when I try to use a simple filter :

weekly D1353 crossed below 0

I realise ,that the signal does not come in the same time as the change from short to long on the plot
( ex: DIA: the 3 rd plot (weekly longsignal2) turns long on the July 5 week; the above filter does not trigger at all) . What do I do wrong?
PS: I think Years ago we discussed about a glitch with this kind of filter?( with DMA)?

KSK8
545 posts
msg #159461
Ignore KSK8
8/15/2022 11:13:34 AM

I'm not an expert with the terminology, but the 'weekly' parameter only applies to indicators itself rather than functions.

so it would be:

set{D1353, weekly ma(10) - weekly dma(10,-5)}

D1353 crossed over 0

---

On another note, I never quite understood people's fascination with the DMA. It's a displaced indicator so it can't be of any general value, unless I'm missing something. It would be helpful if someone can provide an example of the DMA being used to predict a successful trade.

Not criticizing, just strongly curious as I fail to see why the DMA still remains used in filters.

dtatu
134 posts
msg #159462
Ignore dtatu
8/15/2022 11:58:38 AM

From a purely observational point of view, I opened several weekly charts ( mostly ETFs) and noticed that the plots , especially "weekly shortposition1/longposition1" and 2, seem to nicely time weekly reversals.

The problem is: I do not find a trigger/signal to match those changes on the plots.

It might be the fact that : set{D1353, weekly ma(10) - weekly dma(10,-5)} is already a weekly indicator and the choice :" chart-display is weekly" distorts it?

T_Charp13
30 posts
msg #159511
Ignore T_Charp13
8/28/2022 8:59:34 PM

I use the daily version of this filter more and use the dma(2,-1). I also use a few other combinations (like the ema(2)) and wait until ma(2) - dma(2,-1) and ema(2) - dma(2,-1) triggers line up or wait until day 2 of the trigger. Here is my full scan but you can ignore all of the additional stuff I added.

Fetcher[
apply to symlist(spy, qqq, smh, xbi, uvxy, xlf)

draw MACD Histogram(6,13,5)
draw DeMarker(1)
draw DeMarker(5) line .5


set{E1351b,days(ma(2) is above dma(2,-1),100)}
set{E1351a,days(ma(2) is below ma(2,-1),100)}
set{M13xM51, E1351a - E1351b}

set{D1351, ma(2) - dma(2,-1)}
draw D1351 line 0

set{E1,ma(2)-DMA(2,-1) }
set{Shortma2, count(E1 > 0,1)}
set{Longma2, count(E1 < 0,1)}
SET{TRIGGER,1}
draw Shortma2 on plot
draw Longma2 on plot


set{E1352b,days(ema(2) is above dma(2,-1),100)}
set{E1352a,days(ema(2) is below ema(2,-1),100)}
set{M13xM52, E1352a - E1352b}

set{D1352, ema(2) - dma(2,-1)}
draw D1352 line 0

set{E2,ema(2)-DMA(2,-1) }
set{Shortema2, count(E2 > 0,1)}
set{Longema2, count(E2 < 0,1)}
SET{TRIGGER2,0}
draw Shortema2 on plot
draw Longema2 on plot

draw MA(2)
draw DMA(2,-1)

set{E1353b,days(ma(5) is above dma(5,-3),100)}
set{E1353a,days(ma(5) is below ma(5,-3),100)}
set{M13xM53, E1353a - E1353b}

set{D1353, ma(5) - dma(5,-3)}

draw D1353 line 0

set{E3,ma(5)-DMA(5,-3) }
set{Shortma5, count(E3 > 0,1)}
set{Longma5, count(E3 < 0,1)}
SET{TRIGGER3,0}
draw Shortma5 on plot
draw Longma5 on plot


set{E1354b,days(ema(5) is above dma(5,-3),100)}
set{E1354a,days(ema(5) is below ema(5,-3),100)}
set{M13xM54, E1354a - E1354b}

set{D1354, ema(5) - dma(5,-3)}
draw D1354 line 0

set{E4,ema(5)-DMA(5,-3) }
set{Shortema5, count(E4 > 0,1)}
set{Longema5, count(E4 < 0,1)}
SET{TRIGGER4,0}
draw Shortema5 on plot
draw Longema5 on plot




set{E1355b,days(ma(5) is above dma(5,-1),100)}
set{E1355a,days(ma(5) is below ma(5,-1),100)}
set{M13xM55, E1355a - E1355b}

set{D1355, ma(5) - dma(5,-1)}

draw D1355 line 0

set{E5,ma(5)-DMA(5,-1) }
set{Shortdma5-1, count(E5 > 0,1)}
set{Longdma5-1, count(E5 < 0,1)}
SET{TRIGGER5,0}
draw Shortdma5-1 on plot
draw Longdma5-1 on plot



set{E1356b,days(ema(5) is above dma(5,-1),100)}
set{E1356a,days(ema(5) is below ema(5,-1),100)}
set{M13xM56, E1356a - E1356b}

set{D1356, ema(5) - dma(5,-1)}
draw D1356 line 0

set{E6,ema(5)-DMA(5,-1) }
set{Shortedma5-1, count(E6 > 0,1)}
set{Longedma5-1, count(E6 < 0,1)}
SET{TRIGGER6,0}
draw Shortedma5-1 on plot
draw Longedma5-1 on plot


set{E1357b,days(ma(10) is above dma(10,-5),100)}
set{E1357a,days(ma(10) is below ma(10,-5),100)}
set{M13xM57, E1357a - E1357b}

set{D1357, ma(10) - dma(10,-5)}

draw D1357 line 0

set{E7,ma(10)-DMA(10,-5) }
set{Shortma10, count(E7 > 0,1)}
set{Longma10, count(E7 < 0,1)}
SET{TRIGGER7,0}
draw Shortma10 on plot
draw Longma10 on plot

draw DI Difference(1)
draw DI Difference(2)
draw DI Difference(3)
draw DI Difference(5)
draw DI Difference(10)
draw DI Difference(14)
draw DI Difference(20)

add column D1351 {MA(2) -long +short}
add column D1352 {EMA(2) -long +short}
add column D1353 {MA(5) -long +short}
add column D1354 {EMA(5) -long +short}
add column D1355 {DMA(5,-1) -long +short}
add column D1356 {EMA(5,-1) -long +short}
add column D1357 {MA(10) -long +short}

draw price line at close
]





KSK8
545 posts
msg #159513
Ignore KSK8
8/29/2022 4:54:27 AM

I still fail to understand what value the DMA is providing?

Does anyone routinely turn a profit using the DMA as a chief indicator? I'm open minded to this but I struggle to understand why it's even still a thing on SF.

Naturally, I would simply dismiss it as nonsense, however, the same people who dished out pretty handy filters were also the same people who championed it as a "miracle" indicator.



T_Charp13
30 posts
msg #159517
Ignore T_Charp13
8/29/2022 8:41:25 PM

I've been seeing some consistent gains but I used the DMA in conjunction with other signals and not as the only/primary signal.

StockFetcher Forums · Filter Exchange · Help with filter<< >>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.