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

Notification

Icon
Error

Options
Go to last post Go to first unread
gorachand  
#1 Posted : Friday, February 3, 2017 2:54:47 PM(UTC)
gorachand

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 2/19/2012(UTC)
Posts: 106

Thanks: 1 times
Was thanked: 1 time(s) in 1 post(s)

Hello,

 With the help of Mr.William of formulas@equis I tried to fashion an exploration  where  for  5 consecutive bars the Bollinger Bands are inside the Keltner Channels and after being there for 5 consecutive bars they move outside the Keltner Channels.

The indicator code (named TTM William)for the Bollinger Bands moving outside the Keltner Channels  after being there for 5 consecutive bars is

A:=BBandTop(C,20,S,2);  
B:=(Mov(C,20,E)+(ATR(10)*1.5));  
Z:= BBandBot(C,20,S,2);  
G:=(Mov(C,20,E)-(ATR(10)*1.5));  
X:= Sum(A<B AND Z<G, 6) = 6;  
signal:=  Ref(X, -1) AND (A>B OR Z>G);
{Plot}  
signal

The 5 bars  in question are coded thus

A:=BBandTop(C,20,S,2);  
B:=(Mov(C,20,E)+(ATR(10)*1.5));  
Z:= BBandBot(C,20,S,2);  
G:=(Mov(C,20,E)-(ATR(10)*1.5));  
X:= Sum(A<B AND Z<G, 6) = 6;  
signal:= Ref(X, -1) AND (A>B OR Z>G);
{Plot}  
Ref(signal,+1)

The integer 1 is changed to 1,2,3,4 and 5 for each instance and 5 indicators are  coded  TTM1 TTM2  TTM3 TTM4 and TTM5  respectively

The final indicator and Exploration (plugged in Filter) is

  Fml( "TTM William") =1 AND  Fml( "TTM 1") =1 AND  Fml( "TTM 2") =1 AND  Fml( "TTM 3") =1 AND
 Fml( "TTM 4") =1 AND  Fml( "TTM 5") =1

But neither does the indicator plot (though the 6 individual indicators plot successfully) a binary wave  and the exploration says 'results of exploration not defined on calculation date ' (load minimum records deselected)

Where am I going wrong

Can anyone help?

Regards,

Dr.Chatterjee


MS Support  
#2 Posted : Friday, February 3, 2017 5:14:42 PM(UTC)
MS Support

Rank: Advanced Member

Groups: Moderators, Registered, Registered Users, Subscribers
Joined: 10/8/2010(UTC)
Posts: 1,960

Thanks: 92 times
Was thanked: 155 time(s) in 150 post(s)
Hi, I believe I have found the issue with the formula, but you may want to keep in touch with William to make sure this is correct. The forward referencing aspects will never be true on the current day. I have adjusted the Filter/Final formula slightly and this seems to be working. I was using Load 100 Records, you can sometimes get into trouble with Load Minimum Records. Fml("TTM William")=1 AND Ref(Fml("TTM 1"),-1)=1 AND Ref(Fml("TTM 2"),-2)=1 AND Ref(Fml("TTM 3"),-3)=1 AND Ref(Fml("TTM 4"),-4)=1 AND Ref(Fml("TTM 5"),-5)=1
gorachand  
#3 Posted : Friday, February 3, 2017 6:04:07 PM(UTC)
gorachand

Rank: Advanced Member

Groups: Registered, Registered Users
Joined: 2/19/2012(UTC)
Posts: 106

Thanks: 1 times
Was thanked: 1 time(s) in 1 post(s)

Hello MS Support,

                  It seems to be working.Thanks a million.

Regards,

Dr.Chatterjee

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.