Converting EMA scan to DEMA scan


Category:
0
0

Hi Pete,

Much appreciation for the work you do. It helps new traders like myself utilize thinkorswim much better.

My question for you is how do you convert a moving average scan you’ve done a while back to a DEMA scan?

This is the link to the scan you’ve done :

https://www.hahn-tech.com/ans/moving-average-is-x-percent-away-or-greater-from-another-moving-average/#answer-5213

 

Marked as spam
Posted by (Questions: 1, Answers: 1)
Asked on July 17, 2020 6:19 am
139 views
0
Private answer

My response is going to be based on the following article:

https://www.hahn-tech.com/moving-averages-exponential-problems/

Which is that nobody should be using any double exponential moving averages, for any reason, ever.

So rather than provide the solution I will give you the code provided by Thinkorswim for computing the DEMA:

#
# TD Ameritrade IP Company, Inc. (c) 2007-2020
#
input price = close;
input length = 10;
def emaPrice = ExpAverage(price, length);
def emaEmaPrice = ExpAverage(emaPrice, length);
plot DEMA = 2 * emaPrice - emaEmaPrice;
DEMA.SetDefaultColor(GetColor(1));

You can try to work this out on your own but I do not want to publish it here in the forum because I firmly believe nobody should be using DEMA for anything.

Marked as spam
Posted by (Questions: 37, Answers: 4118)
Answered on July 17, 2020 8:53 am
0
Oh, much appreciated I understand your point which I only use it to find early trending stocks on the daily and weekly charts along with other tools. I mean i know that all indicators are lagged which is why I swing trade instead of day trade because that too much stress
( at July 17, 2020 10:24 am)