logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
Leverage  
#1 Posted : Thursday, December 30, 2010 10:38:18 AM(UTC)
Leverage

Rank: Advanced Member

Groups: Registered, Registered Users, Subscribers, Unverified Users
Joined: 1/25/2010(UTC)
Posts: 44
Location: Rome, IT

Hi guys,
to detrendize prices or oscillators I applied this formula:

Close-Ref( Mov(Close, X, Simple ), T)
where X is the number of Time Periods for the Oscillator and T =X /2 + 1.
For example, a 20 period DPO would be:
X = 20
T = (20/2 + 1) = 11

But this kind of formula causes a loss of latest data.

Someone can suggest me another method to detrendize? (for example to detrendize a centered moving average)

Thanks


johnl  
#2 Posted : Thursday, December 30, 2010 6:53:49 PM(UTC)
johnl

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 11/7/2005(UTC)
Posts: 602

I am not sure where I got this code but it attempts to remove
the lag I think you are talking about.
You might apply the below logic to your indicator.


Period:= Input("What Period",1,250,10);
EMA1:= Mov(P,Period,E);
EMA2:= Mov(EMA1,Period,E);
Difference:= EMA1 - EMA2;
ZeroLagEMA:= EMA1 + Difference;
ZeroLagEMA
Users browsing this topic
Guest (Hidden)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.