信號過濾 [金字塔]
- 咨詢內容:
variable:bj=0;a1:=(REF(O,1) + REF(C,1)) / 2;a2:=(H + L + C) / 3;a3:=MAX(MAX(a1,a2),H);a4:=MIN(MIN(a1,a2),L);a5:=IF(a1 < a2,a3 - a4 + a2 - a1,a3 - a4);a6:=IF(a1 > a2,a3 - a4 + a1 - a2,a3 - a4);a7:=a5 / (a5 + a6) * AMOUNT * MAX(ABS(a1 - a2) / (a3 - a4),0.15) / 10000;a8:=a6 / (a5 + a6) * AMOUNT * MAX(ABS(a1 - a2) / (a3 - a4),0.15) / 10000;主力凈買資金:=(a7 - a8) * 2.5;a9:=主力凈買資金;
bb1:=c<ref(c,1);bb2:=c>ref(o,1);
aa:=ref(a9,2)>0;aa1:=ref(a9,2)-ref(a9,1)>ref(a9,2)/2;aa2:=ref(a9,2)-ref(a9,1)<ref(a9,2)/2;aa3:=if(aa,aa1,aa2);cd1:=bb1 and aa3;cd2:=bb2 and aa3;if cd1 then bj:=1;if cd2 then bj:=2;dd1:=c>MAX(ref(c,1),ref(o,1),ref(c,2),ref(o,2));dd2:=c<min(ref(c,1),ref(o,1),ref(c,2),ref(o,2));
cc1:drawtext(cross(bj=1,0.5) and dd2,h*1.0001,'空');cc2:drawtext(cross(bj=2,0.5) and dd1,l*0.9999,'多');
幫忙再加一個過濾信號,cc1和cc2交替出現,不想讓它連續出“多” 或者連續出“空”。謝謝! - 金字塔客服:
http://www.weistock.com/bbs/dispbbs.asp?boardid=4&Id=141135
- 用戶回復:
我在你上次幫我改的里面有多加了兩個指標,然后就變了 麻煩再幫忙改一下 謝謝
- 網友回復:
variable:bj=0;
a1:=(REF(O,1) + REF(C,1)) / 2;
a2:=(H + L + C) / 3;
a3:=MAX(MAX(a1,a2),H);
a4:=MIN(MIN(a1,a2),L);
a5:=IF(a1 < a2,a3 - a4 + a2 - a1,a3 - a4);
a6:=IF(a1 > a2,a3 - a4 + a1 - a2,a3 - a4);
a7:=a5 / (a5 + a6) * AMOUNT * MAX(ABS(a1 - a2) / (a3 - a4),0.15) / 10000;
a8:=a6 / (a5 + a6) * AMOUNT * MAX(ABS(a1 - a2) / (a3 - a4),0.15) / 10000;
主力凈買資金:=(a7 - a8) * 2.5;
a9:=主力凈買資金;
bb1:=c<ref(c,1); bb2:=c>ref(o,1);
aa:=ref(a9,2)>0; aa1:=ref(a9,2)-ref(a9,1)>ref(a9,2)/2; aa2:=ref(a9,2)-ref(a9,1)<ref(a9,2)/2; aa3:=if(aa,aa1,aa2); cd1:=bb1 and aa3; cd2:=bb2 and aa3; dd1:=c>MAX(ref(c,1),ref(o,1),ref(c,2),ref(o,2)); dd2:=c<min(ref(c,1),ref(o,1),ref(c,2),ref(o,2)); if dd1 then bj:=1; if dd2 then bj:=2;
cc1:drawtext(cross(bj=2,0.5) and dd2,h*1.0001,'空'); cc2:drawtext(cross(bj=1,0.5) and dd1,l*0.9999,'多');
有思路,想編寫各種指標公式,程序化交易模型,選股公式,預警公式的朋友
可聯系技術人員 QQ: 511411198 進行 有償 編寫!(不貴!點擊查看價格!)
相關文章
-
沒有相關內容