StockFetcher Forums · Filter Exchange · Detrended Price Oscillator<< >>Post Follow-up
snappyfrog
653 posts
msg #160136
Ignore snappyfrog
2/28/2023 10:47:44 AM

This is a new filter I am trying using the EMA(21) as a trend MA and coming off of a 5 day low.

Thoughts, changes or comments welcome.

Fetcher[
/* Ranging Markets
Set overbought and oversold levels based on observation of past price behavior.

Go long when Detrended Price Oscillator crosses below and then back above the oversold level.
Go short when Detrended Price Oscillator crosses above and then back below the overbought level.
Use stop-losses at all times.

Trending Markets
Only trade in the direction of the trend.

Go long when Detrended Price Oscillator crosses below zero and then turns back above.
Go short when Detrended Price Oscillator crosses above zero and then turns back below.
Only execute trades if the trend is intact (price does not close below the MA). Exit using a trend indicator.

Use stop-losses to protect your position.

Alternative (and more aggressive) rules:

Go long when Detrended Price Oscillator forms a higher trough.
Go short when Detrended Price Oscillator forms a lower peak.
Trade only in the direction of the trend and always use stop losses.*/

market is not otcbb
market is not etf
close < 3
and volume > 50000
draw ema(21)

set{my_dpo, close - MA(20) 11 days ago}
draw my_dpo line 0
set{dpo10, count (my_dpo > my_dpo 10 day low,1)}
draw dpo10
draw low 5 day low
set{lo5, count (low > low 5 day low,1)}
draw lo5 > .99
set{cl21, count (close > ema(21),1)}
draw cl21

set{var1, dpo10 + lo5}
set{buy, var1 + cl21}
draw buy > 1.99

and close crossed above ema(21)
]



Mactheriverrat
3,135 posts
msg #160137
Ignore Mactheriverrat
2/28/2023 4:59:38 PM

Very Interesting !!!!

snappyfrog
653 posts
msg #160142
Ignore snappyfrog
3/5/2023 9:49:19 AM

This is a new filter I am trying using the EMA(21) as a trend MA and coming off of a 5 day low.
Non-penny stock version.
Thoughts, changes or comments welcome.

Submit
Fetcher[
/* Ranging Markets
Set overbought and oversold levels based on observation of past price behavior.

Go long when Detrended Price Oscillator crosses below and then back above the oversold level.
Go short when Detrended Price Oscillator crosses above and then back below the overbought level.
Use stop-losses at all times.

Trending Markets
Only trade in the direction of the trend.

Go long when Detrended Price Oscillator crosses below zero and then turns back above.
Go short when Detrended Price Oscillator crosses above zero and then turns back below.
Only execute trades if the trend is intact (price does not close below the MA). Exit using a trend indicator.

Use stop-losses to protect your position.

Alternative (and more aggressive) rules:

Go long when Detrended Price Oscillator forms a higher trough.
Go short when Detrended Price Oscillator forms a lower peak.
Trade only in the direction of the trend and always use stop losses.*/

market is not otcbb
market is not etf
close > 5
and volume > 500000
draw ema(21)

set{my_dpo, close - MA(20) 11 days ago}
draw my_dpo line 0
set{dpo10, count (my_dpo > my_dpo 10 day low,1)}
draw dpo10
draw low 5 day low
set{lo5, count (low > low 5 day low,1)}
draw lo5 > .99
set{cl21, count (close > ema(21),1)}
draw cl21

set{var1, dpo10 + lo5}
set{buy, var1 + cl21}
draw buy > 1.99

and close crossed above ema(21)
]




Mactheriverrat
3,135 posts
msg #160143
Ignore Mactheriverrat
modified
3/5/2023 11:10:47 AM

Thanks Snappy!!!!

Been running it this morning and I like it.
It's simple and plain.

Sometime's too many Indicators and Oscillators can give someone Analysis paralysis .

nibor100
1,010 posts
msg #160144
Ignore nibor100
3/6/2023 10:59:17 AM

@snappyfrog,

I'm a little confused on a couple of areas of these DPO filters.

1. The Buy criteria in the filters seems to be mostly unrelated to the Go Long descriptions in the comments so are the Buy signals to be used standalone or only when the Go Long conditions are also true?

2. What are you expecting in the results to meet "coming off a 5 day low" as clearly your lo5 indicator can be true longer than just 1 day?

I added "add column days(low equals low 5 day low, 5)" to your non penny stock version and if you sort on that column it shows a high of 4 and a low of -1 (meaning not met) based on running that filter for this past Friday.
Looking at the drawings for VET, which is one of the -1s, it appears the 5 day low has been exceeded by the low price for at least 7 days in a row which seems a bit dated to be "coming off".

Thanks,
Ed S.


snappyfrog
653 posts
msg #160147
Ignore snappyfrog
3/8/2023 2:32:47 AM

Nibor,

There are several ways to look at this filter. I included the moving average
As the trend element if one wanted to trade this way.

The 5 day low could be useful for the ranging markets setup.

Presently, I am looking for a setup on the aggressive style by finding the second
"higher" trough.


snappyfrog
653 posts
msg #160183
Ignore snappyfrog
modified
3/25/2023 9:21:06 AM

I don't see any advantage to using the DPO. It is basically the same as the Momentum of the same length.

Fetcher[
apply to symlist(ba)

draw ema(13)
draw ema(30)

set{my_dpo2, close - MA(10) 22 days ago}
draw my_dpo2 line 0

draw Momentum(22) line 0
]



StockFetcher Forums · Filter Exchange · Detrended Price Oscillator<< >>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.