请留意在一只股票上同时满足以下4个条件的情况:
A:=(3*C+L+O+H)/6;
X:=(20*A+19*REF(A,1)+18*REF(A,2)+17*REF(A,3)+16*REF(A,4)+15*REF(A,5)+
14*REF(A,6)+13*REF(A,7)+12*REF(A,8)+11*REF(A,9)+10*REF(A,10)+9*REF(A,11)+8*REF(A,12)
+7*REF(A,13)+6*REF(A,14)+5*REF(A,15)+4*REF(A,16)+3*REF(A,17)+2*REF(A,18)+
REF(A,20))/210;
主力成本:EMA(X,13),COLORFF00FF,LINETHICK0;
短期底部:LLV(HIGH,30),LINETHICK2,COLORFFCC00;
黄金线:(EMA(C,15)),POINTDOT,LINETHICK4,COLORYELLOW;
生命线:(MA(C,25)),LINETHICK2,COLORMAGENTA;
FF:=EMA(CLOSE,3);
MA15:=EMA(CLOSE,15);
DRAWTEXT(CROSS(FF,MA15),(LOW * 0.99),'买入'),COLOR00FFFF;
DRAWTEXT(CROSS(MA15,FF),(HIGH * 1.02),'卖出'),COLOR00FF00;
将此公式修改“买入”选股公式。
还有就是将下列4个公式设置为盘中预警,条件是在一只股票上同时满足以下4个条件
第一个公式:满足买入
A:=(3*C+L+O+H)/6;
X:=(20*A+19*REF(A,1)+18*REF(A,2)+17*REF(A,3)+16*REF(A,4)+15*REF(A,5)+
14*REF(A,6)+13*REF(A,7)+12*REF(A,8)+11*REF(A,9)+10*REF(A,10)+9*REF(A,11)+8*REF(A,12)
+7*REF(A,13)+6*REF(A,14)+5*REF(A,15)+4*REF(A,16)+3*REF(A,17)+2*REF(A,18)+
REF(A,20))/210;
主力成本:EMA(X,13),COLORFF00FF,LINETHICK0;
短期底部:LLV(HIGH,30),LINETHICK2,COLORFFCC00;
黄金线:(EMA(C,15)),POINTDOT,LINETHICK4,COLORYELLOW;
生命线:(MA(C,25)),LINETHICK2,COLORMAGENTA;
FF:=EMA(CLOSE,3);
MA15:=EMA(CLOSE,15);
DRAWTEXT(CROSS(FF,MA15),(LOW * 0.99),'买入'),COLOR00FFFF;
DRAWTEXT(CROSS(MA15,FF),(HIGH * 1.02),'卖出'),COLOR00FF00;
第二个公式:出现黄柱
MAA5:MA(C,5),COLORWHITE;
MAA10:MA(C,10),COLORGREEN;
MAA30:MA(C,30),COLORMAGENTA,LINETHICK2;
稳赢:IF(MAA10>MAA30,MAA10,MAA30),COLORYELLOW;
A3:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
A4:=SMA(A3,3,1);
A5:=SMA(A4,3,1);
A6:=3*A4-2*A5;
A7:=C-REF(C,1);
A8:=100*EMA(EMA(A7,6),6)/EMA(EMA(ABS(A7),6),6);
买:=LLV(A8,2)=LLV(A8,7) AND COUNT(A8<0,2) AND CROSS(A8,MA(A8,2));
DRAWTEXT(FILTER(买=1,5),LOW-0.05,'进'),COLORYELLOW;
STICKLINE(买,OPEN,CLOSE,2,0),COLORYELLOW;
第三个公式:出手就赢出现
VAR2:=REF(LOW,1);VAR3:=SMA(ABS(LOW-VAR2),3,1)/SMA(MAX(LOW-VAR2,0),3,1)*100;VAR4:=EMA(IF(CLOSE*1.3,VAR3*10,VAR3/10),3);VAR5:=LLV(LOW,30);VAR6:=HHV(VAR4,30);VAR7:=IF(MA(CLOSE,58),1,0);VAR8:=EMA(IF(LOW<=VAR5,(VAR4+VAR6*2)/2,0),3)/618*VAR7;VAR9:=IF(VAR8>100,100,VAR8);STICKLINE(VAR9>-150,0,VAR9,3,0), , COLORFF00FF;底部吸筹指标: (CLOSE-MA(CLOSE,40))/MA(CLOSE,40)*100, , COLOR00FF00;STICKLINE(CROSS(底部吸筹指标,-24),100,0,6,0), , COLORFFFFFF;先知: (CLOSE-MA(CLOSE,5))/MA(CLOSE,5)*100, , COLORFF00FF;可能放量拉升: IF(CROSS(底部吸筹指标,-24),1,0), , COLORFFFFFF;短线获利:STICKLINE(REF("KDJ.J",1)<0 AND "KDJ.J">0,60,0,2,0),COLOR0000FF;VARK1:=(CLOSE-LLV(LOW,27))/(HHV(HIGH,27) -LLV(LOW,27))*100;VARK2:=REVERSE(VARK1);VARK3:=SMA(VARK1,3,1);波段王:=SMA (VARK3,3,1), , COLORRED,LINETHICK2;波段鬼:=SMA(波段王,2.5,1),COLORYELLOW,LINETHICK2;趋势线: 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), ,COLORFF6666,LINETHICK2;RSV9:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100; K1:=SMA(RSV9,3,1);DK1:=K1-REF(K1,1),COLORSTICK;出手就赢:IF(DK1>7 AND REF(DK1,1)<0 AND (DK1-REF(DK1,1))>9,50,0), STICK,COLORYELLOW;DRAWICON(出手就赢>0,50 ,1);买点准备:IF(趋势线<=10,0,10), COLORFF9933,LINETHICK3;STICKLINE( CROSS(趋势线,10),0,73,6,0), COLOR3366FF,;DRAWTEXT(IF(CROSS(趋势线,10),100,0),68,'抄底'),COLORWHITE ;DRAWTEXT(IF(CROSS(10,趋势线),1,0), 10,'$备钱'),COLOR33FFCC,;DRAWTEXT(REF("KDJ.J",1)<0 AND "KDJ.J">0,50,'短买'),,,,COLORRED ,;DRAWTEXT(CROSS(底部吸筹指标,-24),80,'抄底'),COLORWHITE ,;
第四个公式:出现三星(主图)
MA5:EMA(C,5);
MA13:EMA(C,13);
MA21:EMA(C,21);
向上:=COUNT(REF(EMA(C,3),1)<REF(EMA(C,3),2),5)=5 AND EMA(C,3)>REF(EMA(C,3),1);
DRAWTEXT(向上,L*0.993,'★'),COLOR00FF00;
BDD:=C=LLV(C,13);
N:=BARSLAST(BDD);
低:=IF(N,REF(C,N),REF(C,N));
启动:=C>低 AND REF(C=低,1);
DRAWTEXT(启动,L,'★'),COLORFF00FF;
MTM:=C-REF(C,1);
DX:=100*EMA(EMA(MTM,6),6)/EMA(EMA(ABS(MTM),6),6);
买:=IF(LLV(DX,2)=LLV(DX,7) AND COUNT(DX<0,2) AND CROSS(DX,MA(DX,2)),1,0);
DRAWTEXT(FILTER(买=1,5),LOW*0.975,'★'),COLORYELLOW;
VAR2:=REF(EMA(DMA((((HIGH + LOW) + (CLOSE * 2)) / 4.09),0.9),3),1);
DRAWTEXT(CROSS(CLOSE,VAR2),LOW*0.965,'★'),COLORRED;
TJ:=IF((C-REF(C,1))/REF(C,1)>0.025,1,0);
YL:=IF(C>REF(O,BARSLAST(TJ =1)),REF(O,BARSLAST(TJ =1)),0);
FT:=BARSLAST(YL);
YLX:=REF(YL,FT);
BT:=IF(C<OPEN AND REF(C,1)>REF(OPEN,1),REF(C,1),0);
XFT:=BARSLAST(BT);
XYLX:=REF(BT,XFT);
评台调下:=CROSS(XYLX,C);
评台突破:=CROSS(C,YLX);
DRAWTEXT(评台突破 ,L* 0.986, '★'),COLORFFFF00;
发个图
本文仅仅提供源码
组合选股源码
【买入】
FF:=EMA(CLOSE,3);
MA15:=EMA(CLOSE,15);
买入:CROSS(FF,MA15);
【四合一】
FF:=EMA(CLOSE,3);
MA15:=EMA(CLOSE,15);
买入:=CROSS(FF,MA15);
A7:=C-REF(C,1);
A8:=100*EMA(EMA(A7,6),6)/EMA(EMA(ABS(A7),6),6);
买:=LLV(A8,2)=LLV(A8,7) AND COUNT(A8<0,2) AND CROSS(A8,MA(A8,2));
RSV9:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K1:=SMA(RSV9,3,1);
DK1:=K1-REF(K1,1);
出手就赢:=DK1>7 AND REF(DK1,1)<0 AND (DK1-REF(DK1,1))>9;
X1:=COUNT(REF(EMA(C,3),1)<REF(EMA(C,3),2),5)=5 AND EMA(C,3)>REF(EMA(C,3),1);
BDD:=C=LLV(C,13);
N:=BARSLAST(BDD);
低:=IF(N,REF(C,N),REF(C,N));
X2:=C>低 AND REF(C=低,1);
MTM:=C-REF(C,1);
DX:=100*EMA(EMA(MTM,6),6)/EMA(EMA(ABS(MTM),6),6);
买1:=IF(LLV(DX,2)=LLV(DX,7) AND COUNT(DX<0,2) AND CROSS(DX,MA(DX,2)),1,0);
X3:=买1=1;
VAR2:=REF(EMA(DMA((((HIGH + LOW) + (CLOSE * 2)) / 4.09),0.9),3),1);
X4:=CROSS(CLOSE,VAR2);
TJ:=IF((C-REF(C,1))/REF(C,1)>0.025,1,0);
YL:=IF(C>REF(O,BARSLAST(TJ =1)),REF(O,BARSLAST(TJ =1)),0);
FT:=BARSLAST(YL);
YLX:=REF(YL,FT);
X5:=CROSS(C,YLX);
XXX:=(X1 AND X2 AND X3) OR (X1 AND X2 AND X4) OR (X1 AND X2 AND X5) OR (X1 AND X3 AND X4)
OR (X1 AND X3 AND X5) OR (X1 AND X4 AND X5) OR (X3 AND X5 AND X2) OR (X2 AND X4 AND X5) OR (X3 AND X4 AND X5);
HC:买入 AND 买 AND 出手就赢 AND XXX; |