文華指標(biāo)公式源碼(多空參考)
Q1:=CLOSE-REF(CLOSE,1); Q2:=IF(CLOSE-REF(CLOSE,1)>=0,Q1,0); Q3:=REF(CLOSE,1)-CLOSE; Q4:=IF(CLOSE-REF(CLOSE,1)<=0,Q3,0); Q5:=SUM(Q2,90)/SUM(Q4,90); Q6:=100-100/(1+Q5); Q7:=EMA(Q6,21); Q8:=EMA(Q7,5); Q10:=EMA(Q7,3); JJ :=(C*2+H+L)/4; KK := EMA(JJ,13) - EMA(JJ,21); DD := EMA(KK,3); QQ := EMA(KK,10); 長(zhǎng)線1:=IF(DD>=QQ,DD,QQ),LINETHICK1,COLORFFFFAA; 長(zhǎng)線2:=IF(QQ-DD,QQ,DD),LINETHICK1,COLORWHITE; A1:=EMA(CLOSE,7)-EMA(CLOSE,21); B1:=EMA((0.668*REF(A1,1)+0.333*A1),1); 做多:IF(A1>=B1,A1,B1),LINETHICK1,COLORRED; 做空:IF(B1-A1,B1,A1),LINETHICK1,COLORGREEN;
VAR2:=SMA(VAR1,10,1); MS:=SMA(VAR2,5,1);RSV:= ((HHV(HIGH,9)-CLOSE)/(HHV(HIGH,9)-LLV(LOW,9))*100)-70;
RSV1:= (CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100; FATK:=SMA(RSV1,3,1); XX:=SMA(FATK,3,1); VARA:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100; VARB:=SMA(VARA,3,1); VARC:=SMA(VARB,3,1); JS: EMA(3*VARB-2*VARC,2),COLORYELLOW; D:6,COLORLIGHTRED; DI:-6,COLORMAGENTA; DN:90,COLORGREEN; DDN:100,COLORWHITE; VAR11:=LLV(LOW,5)=LLV(LOW,45) && CLOSE>=OPEN*1.04; VAR22:=CLOSE>(REF(HIGH,1)+REF(LOW,1))/2; MR:=VAR11 && VAR22,COLORRED; VAR3:=REF(CLOSE,1); VAR4:=SMA(MAX(CLOSE-VAR3,0),6,1)/SMA(ABS(CLOSE-VAR3),6,1)*100; MC:=CROSS(80,VAR4),COLORGREEN; VAR5:=CROSS(JS,100);VAR6:=CROSS(JS,-6); VAR7:=CROSS(80,JS);VAR8:=CROSS(JS,6); DRAWTEXT(VAR5,85,'注意頂'),COLORBLUE; DRAWTEXT(VAR6,0,'關(guān)注底'),COLORRED; DRAWTEXT(VAR7,95,'空'),COLORGREEN; DRAWTEXT(VAR8,5,'多'),COLORMAGENTA; |
|
來(lái)自: 一名津人 > 《指標(biāo)源碼》