大智慧改型DDX指标公式

AA:=vol/((HIGH-LOW)*2-Abs(CLOSE-OPEN));

买量:=IF(CLOSE>OPEN,AA*(HIGH-LOW),IF(CLOSE<OPEN,AA*((HIGH-OPEN)+(CLOSE-LOW)),VOL/2)){,LINETHICK0,COLORRED};

卖量:=IF(CLOSE>OPEN,0-AA*((HIGH-CLOSE)+(OPEN-LOW)),IF(CLOSE<OPEN,0-AA*(HIGH-LOW),0-VOL/2)){,LINETHICK0,COLORCYAN};

进出量:=买量+卖量{,COLOR00FFFF,LINETHICK0};

stICKLINE(进出量<0,0,进出量,5,0),COLORFF6600;

STICKLINE(进出量<0,0,进出量,4,0),COLORFF9900;

STICKLINE(进出量<0,0,进出量,2.5,0),COLORFFCC00;

STICKLINE(进出量<0,0,进出量,0.5,0),COLORCYAN;

STICKLINE(进出量>0,0,进出量,5,0),COLOR000099;

STICKLINE(进出量>0,0,进出量,4,0),COLOR0000CC;

STICKLINE(进出量>0,0,进出量,4.5,0),COLOR0000FF;

STICKLINE(进出量>0,0,进出量,1.5,0),COLORCC66FF;

N:=5;

M:=13;

五日内净流入:SUM(进出量,N),LINETHICK2,COLORGREEN;

流入:IF(五日内净流入>REF(五日内净流入,1),五日内净流入,0),COLORRED,LINETHICK2;

连红天:BArslAST(COUNT(进出量>0,n));

十三日内翻红天:COUNT(进出量>0,M),COLORRED;

走熊天:BARSLAST (COUNT(五日内净流入<0,n)),COLORCYAn;

走牛天:BARSLAST (COUNT(五日内净流入>0,n)),COLORRED;

强势天:BARSLAST (COUNT((五日内净流入>REF(五日内净流入,n))>0 AND 五日内净流入>0,n));

弱势天:BARSLAST (COUNT((五日内净流入<REF(五日内净流入,n))>0 AND 五日内净流入<0,n));