黄金托底买
操作:=MA(C,3);
HHV(操作,15),LINETHICK1,COLORYELLOW,DOTLINE;
K线分界:HHV(操作,15),LINETHICK1,COLORYELLOW,DOTLINE;
DRAWTEXT(ISLASTBAR,K线分界,STRCAT('K线分界:',CON2STR(K线分界,2))),COLORYELLOW;
VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2);
VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2);
VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR
VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),3.1,0),COLOR00FFFF;
DRAWTEXT(VAR19,L-0.11,'黄'),COLOR00FFFF;
DRAWTEXT(VAR19,L-0.17,'买'),COLOR00FFFF;
VAR1PP:=REF(C,1);
VAR15PP:=SMA(MAX(C-VAR1PP,0),7,1)/SMA(ABS(C-VAR1PP),7,1)*100;
STICKLINE(CROSS(78,VAR15PP),C,O,2,0) ,COLOR00FF00,LINETHICK1;
DRAWTEXT(CROSS(78,VAR15PP),H+0.18,'止') ,COLOR00FF00;
DRAWTEXT(CROSS(78,VAR15PP),H+0.07,'赢') ,COLOR00FF00;
VAR2HH:=IF(CLOSE>OPEN,CLOSE,OPEN);
VAR3HH:=REF(VAR2HH,BARSLAST(VOL=HHV(VOL,60)));
韭菜点:=(LOW<=REF(VAR3HH,1)*0.6 AND REF(LOW,1)>REF(VAR3HH,1)*0.6 AND REF(LOW,2)>REF(VAR3HH,1)*0.6 AND REF(LOW,3)>REF(VAR3HH,1)*0.6),COLORGREEN;
STICKLINE(韭菜点,C,O,3,0),COLORLIRED;
STICKLINE(韭菜点,H*1.1,L-0.15,0,0),COLORLIRED;
DRAWTEXT(韭菜点,L-0.05,'韭菜'),COLORLIRED;
波段底:=(3)*(SMA(((CLOSE - LLV(LOW,27))/(HHV(HIGH,27) - LLV(LOW,27)))*(100),5,1)) - (2)*(SMA(SMA(((CLOSE - LLV(LOW,27))/(HHV(HIGH,27) - LLV(LOW,27)))*(100),5,1),3,1));
DRAWTEXT(CROSS(波段底,3),L-0.04,'底');
买卖:=(EMA(C,3.14)+EMA(C,6.28))/2,COLORRED,NODRAW;
吸:=买卖*0.935,COLORWHITE,NODRAW;
抛:=买卖*1.075,COLORYELLOW,NODRAW;
DRAWTEXT(L<买卖*0.935,L*0.99,'吸1/5')COLORYELLOW;
DRAWTEXT(L<买卖*0.935,L*0.98,'反弹出')COLORYELLOW;
DRAWTEXT(H>买卖*1.075 AND C/REF(C,1)<1.091,H*1.015,'抛一半'),COLORWHITE;
DRAWTEXT(H>买卖*1.075 AND C/REF(C,1)<1.091,H*1.007,'再低吸'),COLORWHITE;