同花顺主力进撤公式
源码
SUM((CLOSE-REF(CLOSE,1))/REF(CLOSE,1)*VOL,0);
总手:VOL;
IF
MAVOL
THEN
RETURN 0;
DRAWGBK(FORMATTIME(1)<10 AND MARKETTYPE
AND TRADETIME>242);
(VOL*(TRADETIME+1))/(FIVEDAYVOL/5*(FROMOPEN+1));
V1:=(C*2+H+L)/4*10;
V2:=EMA(V1,13)-EMA(V1,34);
V3:=EMA(V2,5); V4:=2*(V2-V3)*5.5;
主力撤: IF(V4<=0,V4,0),colorblue;
主力进: IF(V4>=0,V4,0),colorff00ff;
V5:=(HHV(INDEXH,8)-INDEXC)/(HHV(INDEXH,8)-LLV(INDEXL,8))*8;
V6:=EMA(3*V5-2*SMA(V5,18,1),5);
V7:=(INDEXC-LLV(INDEXL,8))/(HHV(INDEXH,8)-LLV(INDEXL,8))*10;
V8:=(INDEXC*2+INDEXH+INDEXL)/4;
V9:=EMA(V8,13)-EMA(V8,34);
VA:=EMA(V9,3);
VB:=(V9-VA)/2;
V11:=3*SMA((C-LLV(L,55))/(HHV(H,55)-LLV(L,55))*100,5,1)-2*SMA(SMA((C-LLV(L,55))/(HHV(H,55)-
LLV(L,55))*100,5,1),3,1);
STRLEFT('☆☆',18),colorwhite;
(CLOSE - LLV(LOW,14)) / (HHV(HIGH,14) - LLV(LOW,14)) * 1.2 * CLOSE;
HLM1:=MA(HHV(H,500),13);
HLM2:=MA(HHV(H,250),13);
HLM3:=MA(HHV(H,89),13);
HLM4:=MA(LLV(L,500),13);
HLM5:=MA(LLV(L,250),13);
HLM6:=MA(LLV(L,89),13);
HLM7:=MA((HLM1*0.558+HLM2*0.558+HLM3*0.558+HLM4*0.96+HLM5*0.96+HLM6*0.96)/6,17);
HLM8:=MA((HLM1*0.55+HLM2*0.55+HLM3*0.65+HLM4*1.25+HLM5*1.23+HLM6*1.2)/6,17);
HLM9:=MA((HLM1*0.68+HLM2*0.68+HLM3*0.68+HLM4*1.3+HLM5*1.3+HLM6*1.3)/6,17);
HLM10:=MA((HLM7*3+HLM8*2+HLM9)/6*1.738,17);
HLM11:=SMA(ABS(L-REF(L,1)),3,1)/SMA(MAX(L-REF(L,1),0),3,1)*100;
HLM12:=MA(IF(C*1.35<=HLM10,HLM11*10,HLM11/10),3);
HLMH:=HHV(HLM12,30);
SUM((CLOSE-REF(CLOSE,1))/REF(CLOSE,1)*VOL,0);
R1:=(ZDMR)-(ZDMC);
R2:=(BDMR)-(BDMC);
R3:=(ZDMC)-(ZDMR);
R4:=(BDMC)-(BDMR);
主买:SUM(R1,2),coloryellow ,linethick1;
被买:SUM(R2,2),colorlired ,linethick1;
主卖:SUM(R3,2),colorgreen,linethick1;
被卖:SUM(R4,2),colorliblue,DOTLINE ,linethick1;
STICKLINE(主买>0,主买,0,3,0,) ,coloryellow;
STICKLINE(被买>0,被买,0,3,0,) ,colorlired;
STICKLINE(主卖>0,主卖,0,2,0,) ,colorgreen;
STICKLINE(被卖>0,被卖,0,2,0,) ,colorliblue;
DIFIF1:=EMA(CLOSE,6) - EMA(CLOSE,10);
DEAEA1:=EMA(DIFIF1,5);
MACD1:=2*(DIFIF1-DEAEA1),STICK;
MACD2:=EMA(MACD1,3);
STICKLINE(MACD1>MACD2 AND MACD1>0,0,MACD1,1,0),colorred;
STICKLINE(MACD1>MACD2 AND MACD1<0,0,MACD1,1,0),colorgreen;
STICKLINE(MACD1<MACD2,0,MACD1,1,0),COLORCBCBC0;
STICKLINE(MACD1>=0 OR MACD1<=0,0,0,50,1),colorwhite;
DRAWICON(CROSS(DIFIF1,DEAEA1),DIFIF1+0.1,1);
DRAWICON(CROSS(DEAEA1,DIFIF1),-0.5,2);
DRAWTEXT(CROSS(DIFIF1,DEAEA1),DIFIF1,'○'),LINETHICK1, coloryellow;
N:=20;JJ:=(HIGH+LOW+CLOSE)/3;QJ0:=VOL/IF(HIGH=LOW,4,HIGH-LOW);
QJ1:=IF(CAPITAL=0,QJ0*(JJ-MIN(CLOSE,OPEN)),QJ0*IF(HIGH=LOW,1,(MIN(OPEN,CLOSE)-LOW)));
QJ2:=IF(CAPITAL=0,QJ0*(MIN(OPEN,CLOSE)-LOW),QJ0*IF(HIGH=LOW,1,(JJ-MIN(CLOSE,OPEN))));
QJ3:=IF(CAPITAL=0,QJ0*(HIGH-MAX(OPEN,CLOSE)),QJ0*IF(HIGH=LOW,1,(HIGH-MAX(OPEN,CLOSE))));
QJ4:=IF(CAPITAL=0,QJ0*(MAX(CLOSE,OPEN)-JJ),QJ0*IF(HIGH=LOW,1,(MAX(CLOSE,OPEN)-JJ)));
N:=22;JJ:=(HIGH+LOW+CLOSE)/3;
QJ0:=VOL/IF(HIGH=LOW,4,HIGH-LOW);
JJ:=(HIGH+LOW+CLOSE)/3;QJ0:=VOL/IF(HIGH=LOW,4,HIGH-LOW);
QJ3:=QJ1+QJ2;QJ2:=QJ1+QJ3;DD:=(QJ1-QJ2)/(QJ1+QJ2)*100;
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;
STICKLINE(进出量<0,0,进出量,4,0),COLORFF6600;
STICKLINE(进出量<0,0,进出量,3,0),COLORFF9900;
STICKLINE(进出量<0,0,进出量,1.5,0),COLORFFCC00;
STICKLINE(进出量<0,0,进出量,0.5,0),colorcyan;
STICKLINE(进出量>0,0,进出量,4,0),COLOR000099;
STICKLINE(进出量>0,0,进出量,3,0),COLOR0000CC;
STICKLINE(进出量>0,0,进出量,1.5,0),COLOR0000FF;
STICKLINE(进出量>0,0,进出量,0.5,0),COLORCC66FF;
VAR1:=C-REF(C,1);
VAR2:=O-REF(O,1);
VAR3:=H-REF(H,1);
VAR4:=L-REF(L,1);
VAR5:=(VAR1+VAR2+VAR3+VAR4)/4;
HLM1:=MA(HHV(H,500),13);
HLM2:=MA(HHV(H,250),13);
HLM3:=MA(HHV(H,89),13);
HLM4:=MA(LLV(L,500),13);
HLM5:=MA(LLV(L,250),13);
HLM6:=MA(LLV(L,89),13);
HLM7:=MA((HLM1*0.558+HLM2*0.558+HLM3*0.558+HLM4*0.96+HLM5*0.96+HLM6*0.96)/6,17);
HLM8:=MA((HLM1*0.55+HLM2*0.55+HLM3*0.65+HLM4*1.25+HLM5*1.23+HLM6*1.2)/6,17);
HLM9:=MA((HLM1*0.68+HLM2*0.68+HLM3*0.68+HLM4*1.3+HLM5*1.3+HLM6*1.3)/6,17);
A1:=EMA(C,12)-EMA(C,25);
A2:=EMA(A1,6);
STICKLINE(A2>=0,A2,0,5,0),colorwhite;
STICKLINE(A2<0,A2,0,5,0),COLORD4FF7F;
STICKLINE(A1<0,A1,0,5,0),COLORB00058;
STICKLINE(A1>=0,A1,0,5,0),colorred;
DIFIF1:=EMA(CLOSE,6) - EMA(CLOSE,10);
DEAEA1:=EMA(DIFIF1,5);BUYCOUNT;
SELLCOUNT;
(HHV(CLOSE,10)-LLV(CLOSE,10))/CLOSE<0.03;CLOSE;
DRAWICON(CROSS(DIFIF1,DEAEA1),DIFIF1+0.1,1);
DRAWICON(CROSS(DEAEA1,DIFIF1),-0.5,2);
DRAWTEXT(CROSS(DIFIF1,DEAEA1),DIFIF1,'○'),LINETHICK1, coloryellow;
DEAEA1:=EMA(DIFIF1,5);