大智慧完美买卖优化主图指标公式

input:P1(28,20,32),P2(32,32,35),P3(35,35,38),n(3,0,20),m(20,0,100);

ma5:ma(close,5);

ma10:ma(close,10);

ma20:ma(close,20);

ma30:ma(close,30);

ma60:ma(close,60);

VAR1:=IF(DATE<1500830 AND DATE>900101,1,0);

VAR2:=LLV(LOW,10);

VAR3:=HHV(HIGH,25);

K1:=(P1/10)*VAR1*100;

K2:=(P2/10)*VAR1*100;

K3:=(P3/10)*VAR1*100;

RSV:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;

K:=SMA(RSV,3,1);

D:=SMA(K,3,1);

J:=3*K-2*D;

X:=LLV(J,2)=LLV(J,8);

Y:=IF(crOSS(J,REF(J+0.01,1)) AND X AND J<20,30,0);

{www.zhibiaow.com 指标网_大智慧股票指标公式}

主力:=EMA( (CLOSE-MA(CLOSE,n))/MA(CLOSE,n)*4800,2);

散户:=EMA( (CLOSE-MA(CLOSE,m))/MA(CLOSE,m)*4800,7);

动能趋势线:=100*EMA((CLOSE-VAR2)/(VAR3-VAR2)*4,4)*VAR1;

DRAWTEXT(CROSS(动能趋势线,K1),HIGH*1.02,'风险'),COLORGREEN;

DRAWTEXT(CROSS(动能趋势线,K2),HIGH*1.02,'减仓'),COLOR00FF00;

DRAWTEXT(CROSS(动能趋势线,K3),HIGH*1.02,'出局'),COLORWHITE;

DRAWTEXT(CROSS(J,REF(J+0.01,1)) AND X AND J<20,LOW,'短进'),COLORFF00FF;

DRAWTEXT(CROSS(主力,散户) AND 主力<0 AND 散户<0,LOW,'见 底'),COLORRED;

DRAWICON(CROSS(主力,散户) AND 主力<0 AND 散户<0,LOW,1);