首頁 股票學校 股票入門 選股 買入 看盤 跟莊 短線 炒股技巧 技術指標 k線圖 MACD 均線 成交量 股票書籍 股票視頻 網站導航

767股票學習網 > 股票學校 > 飛狐公式 > 正文

權證操作--飛狐公式

INPUT: P1(2.7,2,3.2),P2(3.13,3,3.5),P3(3.43,3,3.8),p4(3.71,3.5,3.9),n(21,3,100),n1(3,3,100),zz(1,1,2); //zz是多空顯示開關。
m1:=ma(c,5);
m2:ma(c,20),COLORGREEN;
均線變異:if(m1>m2,m2,m1),,Color0000FF;
partline(均線變異>ref(均線變異,1) and 均線變異=m2,均線變異),linethick2,COLORred;
var1:=(hhv(high,n)-close)/(hhv(high,n)-llv(low,n))*100;
var3:=(close-llv(low,n))/(hhv(high,n)-llv(low,n))*100;
var6:=var3-var1;
z:=ma(var6,n1);
stickline(z>=0 {and zz=2},O,C,6,0),colorred;
stickline(z>=0 {and zz=2},H,max(O,C),0,1),colorred;
stickline(z>=0 {and zz=2},min(O,C),L,0,1),COLORred;
stickline(z<0 {and zz=1},O,C,6,1),COLORCYAN;
stickline(z<0 {and zz=1},h,max(O,c),0,1),COLORCYAN;
stickline(z<0 {and zz=1},min(O,C),l,0,1),COLORCYAN;
stickline(z>=0 and m2>c,O,C,6,0),COLORBLUE;
stickline(z>=0 and m2>c,H,max(O,C),0,1),COLORBLUE;
stickline(z>=0 and m2>c,min(O,C),L,0,1),COLORBLUE;
stickline(z<0 and m2<c,O,C,6,1),COLORYELLOW;
stickline(z<0 and m2<c,h,max(O,c),0,1),COLORYELLOW;
stickline(z<0 and m2<c,min(O,C),l,0,1),COLORYELLOW;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(z,0),1,0),l,'平空開多!'),COLORRED;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(0,z),1,0),h,'平多開空!'),COLORgreen;
Var2:=LLV(LOW,10);
Var3:=HHV(HIGH,25);
警戒線:= p1 ;
減倉線:= p2 ;
賣出線:= p3 ;
空頭線:=p4;
動力線:= EMA((CLOSE-Var2)/(Var3-Var2)*4,4);
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(動力線,警戒線),1,0),c,'預警 '),ALIGN4,colorwhite;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(動力線,減倉線),1,0),c,'減磅 '),ALIGN5,COLORYELLOW;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(動力線,賣出線),1,0),c,'出局?'),ALIGN4,COLORGREEN ;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(動力線,空頭線),1,0),c,'與虎謀皮 '),ALIGN3,COLORRED;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(警戒線,動力線),1,0),c,'預警確認 '),ALIGN3,COLORRED;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(減倉線,動力線),1,0),c,'減磅確認 '),ALIGN3,COLORRED;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(賣出線,動力線),1,0),c,'出局確認'),ALIGN3,COLORRED ;
DRAWTEXT(IF(RANGE(BARPOS,SYSPARAM(1)-2,SYSPARAM(1)+1) AND CROSS(空頭線,動力線),1,0),c,'虎皮到手'),ALIGN4,COLORRED ;

{DRAWICON(CROSS(動力線,警戒線),h,1);
DRAWICON(CROSS(動力線,減倉線),h,3);}
DRAWICON(CROSS(動力線,賣出線),h,2);

WW:=(簡單移動平均(收盤價,4)+簡單移動平均(收盤價,8)+簡單移動平均(收盤價,16)+簡單移動平均(收盤價,32))/4;
畫圖標(交叉函數(收盤價,WW),最低價-0.02,4);
畫圖標(交叉函數(WW,收盤價),最高價+0.06,5);
顯示文字(交叉函數(收盤價,WW),最低價-0.02,' 開多');
顯示文字(交叉函數(WW,收盤價),最高價+0.06,' 多平');  

上一篇文章:

下一篇文章:

 




767股票學習網 | 手機版 | 微信 | 微博 | 聯系站長





香港特码资料部