通达信BIAS短线起爆点源码公式:
n1:=5;n2:=10;n3:=20;
BIAS1:(CLOSE-MA(CLOSE,N1))/MA(CLOSE,N1)*100,LINETHICK1;
BIAS2:(CLOSE-MA(CLOSE,N2))/MA(CLOSE,N2)*100,LINETHICK2;
BIAS3:(CLOSE-MA(CLOSE,N3))/MA(CLOSE,N3)*100,LINETHICK4;
上升BIAS1:IF(BIAS1>REF(BIAS1,1),BIAS1,DRAWNULL),COLORRED,LINETHICK1;
上升BIAS2:IF(BIAS2>REF(BIAS2,1),BIAS2,DRAWNULL),COLORRED,LINETHICK2;
上升BIAS3:IF(BIAS3>REF(BIAS3,1),BIAS3,DRAWNULL),COLORRED,LINETHICK4;
转折1:=REF(BIAS1,2)>REF(BIAS1,1) AND REF(BIAS1,1)<BIAS1 AND REF(BIAS1,2)<BIAS1;
转折2:=REF(BIAS2,2)>REF(BIAS2,1) AND REF(BIAS2,1)<BIAS2 AND REF(BIAS2,2)<BIAS2;
转折3:=REF(BIAS3,2)>REF(BIAS3,1) AND REF(BIAS3,1)<BIAS3 AND REF(BIAS3,2)<BIAS3;
同时转折买点:=转折1 AND 转折2 AND 转折3;
DRAWICON(同时转折买点 AND C>MA(C,5)
AND MA(C,5)>REF(MA(C,5),1) AND REF(MA(C,5),1)>REF(MA(C,5),2) ,MIN(MIN(BIAS1,BIAS2),BIAS3),1);
BIAS角度计算:
n1:=5;n2:=10;n3:=20;
BIAS1:=(CLOSE-MA(CLOSE,N1))/MA(CLOSE,N1)*100,LINETHICK1;
BIAS2:=(CLOSE-MA(CLOSE,N2))/MA(CLOSE,N2)*100,LINETHICK2;
BIAS3:=(CLOSE-MA(CLOSE,N3))/MA(CLOSE,N3)*100,LINETHICK4;
MAXBIAS1:=IF(BIAS1>REF(BIAS1,1),BIAS1,0);
角度计算1:IF(BIAS1>REF(BIAS1,1),(MAXBIAS1-MIN(BIAS1,REF(BIAS1,1)))/
(ABS(BIAS1)+ABS(REF(BIAS1,1))),0),LINETHICK1;
MAXBIAS2:=IF(BIAS2>REF(BIAS2,1),BIAS2,0);
角度计算2:IF(BIAS2>REF(BIAS2,1),(MAXBIAS2-MIN(BIAS2,REF(BIAS2,1)))/
(ABS(BIAS2)+ABS(REF(BIAS2,1))),0),LINETHICK1;
MAXBIAS3:=IF(BIAS3>REF(BIAS3,1),BIAS3,0);
角度计算3:IF(BIAS3>REF(BIAS3,1),(MAXBIAS3-MIN(BIAS3,REF(BIAS3,1)))/
(ABS(BIAS3)+ABS(REF(BIAS3,1))),0),LINETHICK1;
{加入大庆老杨的指标}
大盘6日:=(INDEXC-MA(INDEXC,6))/MA(INDEXC,6)*100;
大盘12日:=(INDEXC-MA(INDEXC,12))/MA(INDEXC,12)*100;
大盘24日:=(INDEXC-MA(INDEXC,24))/MA(INDEXC,24)*100;
大盘:=(大盘6日 + 大盘12日 + 大盘24日)/3;
个股6日:=(C-MA(C,6))/MA(C,6)*100;
个股12日:=(C-MA(C,12))/MA(C,12)*100;
个股24日:=(C-MA(C,24))/MA(C,24)*100;
个股:=(个股6日 + 个股12日 + 个股24日)/3;
强势出击:大盘>REF(大盘,1) AND CROSS(个股,大盘); |