{正大自用C}
VAR0:=MA(100 * (CLOSE - LLV(CLOSE,34))/(HHV(HIGH,34) - LLV(LOW,34)),5) - 20;
VAR1:=100 - 3 * SMA((CLOSE - LLV(LOW,75))/(HHV(HIGH,75) - LLV(LOW,75)) * 100,20,1) + 2 * SMA(SMA((CLOSE - LLV(LOW,75))/(HHV(HIGH,75) - LLV(LOW,75)) * 100,20,1),15,1);
VAR2:=100 - 3 * SMA((OPEN - LLV(LOW,75))/(HHV(HIGH,75) - LLV(LOW,75)) * 100,20,1) + 2 * SMA(SMA((OPEN - LLV(LOW,75))/(HHV(HIGH,75) - LLV(LOW,75)) * 100,20,1),15,1);
VAR3:=VAR1 < REF(VAR2,1) AND VOL > REF(VOL,1) AND CLOSE > REF(CLOSE,1);
DRAWTEXT(VAR3 AND COUNT(VAR3,30)=1,6,'★关注'),COLORYELLOW;
STICKLINE(VAR3 AND COUNT(VAR3,30)=1,6,10,10,1),COLORYELLOW;
VAR4:=(HIGH + LOW + CLOSE)/3;
VAR5:=(VAR4 - MA(VAR4,14))/(0.015 * AVEDEV(VAR4,14));
VAR6:=(VAR4 - MA(VAR4,70))/(0.015 * AVEDEV(VAR4,70));
VAR7:=IF(VAR5 >= 150 AND VAR5 < 200 AND VAR6 >= 150 AND VAR6 < 200,100,0);
VAR8:=IF(VAR5 <= -150 AND VAR5 > -200 AND VAR6 <= -150 AND VAR6 > -200,-10,VAR7);
VAR9:=(CLOSE - MA(CLOSE,13))/MA(CLOSE,13) * 100;
VAR10:=100 - ABS(VAR9);
VAR11:=IF(VAR10 < 90,VAR10,100);
VAR12:=IF(VAR0 > 0,VAR0,0);
VAR13:=IF(VAR6 >= 200 AND VAR5 >= 150,15,IF(VAR6 <= -200 AND VAR5 <= -150,-15,VAR8)) + 60;
VAR14:=VAR12 > 48 AND VAR13 > 60 AND VAR11 < 100;
VAR15:=DYNAINFO(23)/DYNAINFO(22);
VAR16:=DYNAINFO(17);
VAR26:=MAX(DYNAINFO(3),DYNAINFO(5));
VAR27:=MIN(DYNAINFO(3),DYNAINFO(6));
VAR28:=VAR26 - VAR27;
VAR29:=VAR27 + VAR28 * 0.5/8;
VAR30:=EMA(CLOSE,3);
VAR31:=VAR27 + VAR28 * 7/8;
VAR35:=DYNAINFO(11);
VAR36:=55;
VAR37:=8;
VAR38:=3;
VAR39:=(EMA(CLOSE,VAR37) - EMA(CLOSE,VAR36)) * 10;
VAR40:=EMA(VAR39,VAR38);
VAR41:=(CLOSE - VAR35)/VAR35 < -0.005;
VAR42:=(CLOSE - VAR35)/VAR35 < -0.03;
VAR44:=(CLOSE - VAR35)/VAR35 > 0.005;
VAR48:=CROSS(VAR39,VAR40) AND VAR39 < -0.3;
VAR17:=IF(YEAR >= 2038 AND MONTH >= 1,0,1);
VAR18:=REF(LOW,1) * VAR17;
VAR19:=SMA(ABS(LOW - VAR18),3,1)/SMA(MAX(LOW - VAR18,0),3,1) * 100 * VAR17;
VAR20:=EMA(IF(CLOSE * 1.3,VAR19 * 10,VAR19/10),3) * VAR17;
VAR21:=LLV(LOW,30) * VAR17;
VAR22:=HHV(VAR20,30) * VAR17;
VAR23:=IF(MA(CLOSE,58),1,0) * VAR17;
VAR24:=EMA(IF(LOW <= VAR21,(VAR20 + VAR22 * 2)/2,0),3)/618 * VAR23 * VAR17;
【想好就买】:IF(VAR24 > 1,1,VAR24) * VAR17,COLOR3366FF;
VAR25:=STICKLINE(IF(VAR24 > 1,1,VAR24) * VAR17 > -150,0,IF(VAR24 > 1,1,VAR24) * VAR17,8,0);
正大2009~提醒:STICKLINE(IF(VAR24 > 1,1,VAR24) * VAR17 > -150,0,IF(VAR24 > 1,1,VAR24) * VAR17,8,0),COLORMAGENTA;
庄家在吸筹:STICKLINE(IF(VAR24 > 1,1,VAR24) * VAR17 > -150,0,IF(VAR24 > 1,1,VAR24) * VAR17,8,0),COLORMAGENTA;
DRAWTEXT(LONGCROSS(VAR29,VAR30,6)=1,5.1,'▲想好就买'),COLOR0066FF;
STICKLINE(LONGCROSS(VAR29,VAR30,6)=1,5.1,10,16,0),COLOR0066FF;
VAR117:=EMA(EMA(CLOSE,13),13);
VAR32:=(VAR117 - REF(VAR117,1))/REF(VAR117,1) * 1000;
VAR33:=CROSS(VAR32,0);
VAR34:=FILTER(IF(VAR33,1,0),5);
VAR45:=VAR32 < REF(VAR32,1) AND VAR32 > 0.5;
VAR46:=VAR32 > 0;
VAR47:=VAR32 > REF(VAR32,1) AND VAR32 < -0.2;
买:FILTER(VAR42 AND VAR47 AND VAR48,13),LINETHICK6,COLORRED;
DRAWTEXT(FILTER(VAR42 AND VAR47 AND VAR48,13),3,'买'),LINETHICK3,COLORRED;
1.当盘中出现红箭头上的‘买’字发出预警。
通达信并不支持分时预警,只能当副图,或者引入分时主图显示。代码如下
VAR0:=MA(100 * (CLOSE - LLV(CLOSE,34))/(HHV(HIGH,34) - LLV(LOW,34)),5) - 20;
VAR1:=100 - 3 * SMA((CLOSE - LLV(LOW,75))/(HHV(HIGH,75) - LLV(LOW,75)) * 100,20,1) + 2 * SMA(SMA((CLOSE - LLV(LOW,75))/(HHV(HIGH,75) - LLV(LOW,75)) * 100,20,1),15,1);
VAR2:=100 - 3 * SMA((OPEN - LLV(LOW,75))/(HHV(HIGH,75) - LLV(LOW,75)) * 100,20,1) + 2 * SMA(SMA((OPEN - LLV(LOW,75))/(HHV(HIGH,75) - LLV(LOW,75)) * 100,20,1),15,1);
VAR3:=VAR1 < REF(VAR2,1) AND VOL > REF(VOL,1) AND CLOSE > REF(CLOSE,1);
XG1:=VAR3 AND COUNT(VAR3,30)=1;
VAR4:=(HIGH + LOW + CLOSE)/3;
VAR5:=(VAR4 - MA(VAR4,14))/(0.015 * AVEDEV(VAR4,14));
VAR6:=(VAR4 - MA(VAR4,70))/(0.015 * AVEDEV(VAR4,70));
VAR7:=IF(VAR5 >= 150 AND VAR5 < 200 AND VAR6 >= 150 AND VAR6 < 200,100,0);
VAR8:=IF(VAR5 <= -150 AND VAR5 > -200 AND VAR6 <= -150 AND VAR6 > -200,-10,VAR7);
VAR9:=(CLOSE - MA(CLOSE,13))/MA(CLOSE,13) * 100;
VAR10:=100 - ABS(VAR9);
VAR11:=IF(VAR10 < 90,VAR10,100);
VAR12:=IF(VAR0 > 0,VAR0,0);
VAR13:=IF(VAR6 >= 200 AND VAR5 >= 150,15,IF(VAR6 <= -200 AND VAR5 <= -150,-15,VAR8)) + 60;
VAR14:=VAR12 > 48 AND VAR13 > 60 AND VAR11 < 100;
VAR15:=DYNAINFO(23)/DYNAINFO(22);
VAR16:=DYNAINFO(17);
VAR26:=MAX(DYNAINFO(3),DYNAINFO(5));
VAR27:=MIN(DYNAINFO(3),DYNAINFO(6));
VAR28:=VAR26 - VAR27;
VAR29:=VAR27 + VAR28 * 0.5/8;
VAR30:=EMA(CLOSE,3);
VAR31:=VAR27 + VAR28 * 7/8;
VAR35:=DYNAINFO(11);
VAR36:=55;
VAR37:=8;
VAR38:=3;
VAR39:=(EMA(CLOSE,VAR37) - EMA(CLOSE,VAR36)) * 10;
VAR40:=EMA(VAR39,VAR38);
VAR41:=(CLOSE - VAR35)/VAR35 < -0.005;
VAR42:=(CLOSE - VAR35)/VAR35 < -0.03;
VAR43:=REF(BARSLASTCOUNT(VAR35 >= REF(VAR35,1)),1) >= 4 AND (CLOSE - VAR35)/VAR35 < 0.005;
VAR44:=(CLOSE - VAR35)/VAR35 > 0.005;
VAR48:=CROSS(VAR39,VAR40) AND VAR39 < -0.3;
VAR17:=IF(YEAR >= 2038 AND MONTH >= 1,0,1);
VAR18:=REF(LOW,1) * VAR17;
VAR19:=SMA(ABS(LOW - VAR18),3,1)/SMA(MAX(LOW - VAR18,0),3,1) * 100 * VAR17;
VAR20:=EMA(IF(CLOSE * 1.3,VAR19 * 10,VAR19/10),3) * VAR17;
VAR21:=LLV(LOW,30) * VAR17;
VAR22:=HHV(VAR20,30) * VAR17;
VAR23:=IF(MA(CLOSE,58),1,0) * VAR17;
VAR24:=EMA(IF(LOW <= VAR21,(VAR20 + VAR22 * 2)/2,0),3)/618 * VAR23 * VAR17;
XG2:=LONGCROSS(VAR29,VAR30,6)=1;
VARR17:=EMA(EMA(CLOSE,13),13);
VAR32:=(VARR17 - REF(VARR17,1))/REF(VARR17,1) * 1000;
VAR33:=CROSS(VAR32,0);
VAR34:=FILTER(IF(VAR33,1,0),5);
VAR45:=VAR32 < REF(VAR32,1) AND VAR32 > 0.5;
VAR46:=VAR32 > 0;
VAR47:=VAR32 > REF(VAR32,1) AND VAR32 < -0.2;
XG3:=FILTER(VAR42 AND VAR47 AND VAR48,3);
XG:XG1 OR XG2 OR XG3;