2014-09-11 36 views
1

我正在複製一些我在AmiBroker(我是AFL新手)編寫的代碼。這段代碼觸發了Longs,但從未觸發過短。價格數據有很多短褲(由C#代碼證明)。我錯過了什麼? Shorts基本上與Longs相反。AmiBroker AFL code - Shorts not firing

Buy = EMA( Close , 60) > Ref(EMA( Close , 60) , -2) 
AND ref(Close, -2) < Ref(EMA( Close , 15) , -2) 
AND Ref(Close, -1) > Ref(EMA( Close , 15) , -1) 
AND Close > EMA( Close , 15) 
AND Close > Open; 

Sell = Close < EMA( Close , 15); 

Short = EMA( Close , 60) < Ref(EMA( Close , 60) , -2) 
AND Ref(Close, -2) > Ref(EMA( Close , 15) , -2) 
AND Ref(Close, -1) < Ref(EMA( Close , 15) , -1) 
AND Close < EMA( Close , 15) 
AND Close < Open; 

Cover = Close > EMA( Close , 15); 
+1

什麼是AmiBroker?什麼是AFL?如果你解釋了這是什麼,以及它與C#編程有什麼關係,你可能會得到更多的答案。 – RenniePet 2014-09-11 09:46:04

+0

這不是C#,但我沒有足夠的代表來創建新的標籤。 AmiBroker的人會知道它是什麼。 :) – 2014-09-11 11:44:08

+0

搜索了AmiBroker,這些是通常用於有關問題的一些標籤。所以你不會感到沮喪的C#程序員出現在這裏。 – RenniePet 2014-09-11 11:57:39

回答

1

D'oh!分析儀的屬性設置爲只啓動Longs!我把它設置成長褲和短褲,一切都很好。