副图公式源码支持 手机/电脑
M:=20;
GUP1:=MA(C,5);
GUP2:=MA(C,10);
GUP3:=MA(C,30);
GUP4:=SMA(MAX(CLOSE-REF(CLOSE,1),0),17,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),17,1)*100;
GUP5:=BARSLAST(CROSS(GUP1,GUP2));
GUP6:=BARSLAST(CROSS(GUP1,GUP3));
GUP7:=BARSLAST(CROSS(GUP2,GUP3));
GUP8:=GUP5>=GUP6 AND GUP6>GUP7 AND GUP5-GUP7<M;
GUP9:=COUNT(CROSS(GUP1,GUP2),GUP5+1)=1 AND COUNT(CROSS(GUP1,GUP3),GUP5+1)=1 AND CROSS(GUP2,GUP3) AND GUP1>GUP2 AND GUP2>GUP3;
GUP10:=GUP8 AND GUP9;
建仓:GUP8 AND GUP9,NODRAW,COLORCCCCCC;
GUP11:=COUNT(建仓,BARSLAST(建仓)+1)=1 AND COUNT(CROSS(GUP3,GUP1),BARSLAST(建仓)+1)=0;
回踩OW<=GUP3 AND CLOSE>GUP3 AND GUP11 AND BARSLAST(建仓)>0,NODRAW,COLORLIRED;
GUP12:=COUNT(建仓,BARSLAST(建仓)+1)=1 AND CROSS(GUP3,GUP1) AND COUNT(CROSS(GUP3,GUP1),BARSLAST(建仓)+1)=1;
卖出:GUP12>0,NODRAW,COLORGREEN;
区间:COUNT(建仓,BARSLAST(建仓)+1)=1 AND COUNT(卖出,BARSLAST(建仓)+1)=0,NODRAW,COLOR696960;
STICKLINE(区间>0,0,70,4,0),COLOR696969;
STICKLINE(卖出>0,0,70,4,0),COLORGREEN;
DRAWTEXT(卖出,10,'---卖出'),COLORGREEN;
STICKLINE(回踩>0,0,70,4,0),COLORLIRED;
DRAWTEXT(回踩,35,'---回踩'),COLORLIRED;
STICKLINE(建仓>0,0,70,4,0),COLORWHITE;
DRAWTEXT(建仓,60,'---建仓'),COLORWHITE;
选股公式源码
{选股公式一:建仓}
M:=20;
GUP1:=MA(C,5);
GUP2:=MA(C,10);
GUP3:=MA(C,30);
GUP4:=SMA(MAX(CLOSE-REF(CLOSE,1),0),17,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),17,1)*100;
GUP5:=BARSLAST(CROSS(GUP1,GUP2));
GUP6:=BARSLAST(CROSS(GUP1,GUP3));
GUP7:=BARSLAST(CROSS(GUP2,GUP3));
GUP8:=GUP5>=GUP6 AND GUP6>GUP7 AND GUP5-GUP7<M;
GUP9:=COUNT(CROSS(GUP1,GUP2),GUP5+1)=1 AND COUNT(CROSS(GUP1,GUP3),GUP5+1)=1 AND CROSS(GUP2,GUP3) AND GUP1>GUP2 AND GUP2>GUP3;
建仓:GUP8 AND GUP9,COLORCCCCCC;
{选股公式二:回踩}
M:=20;
GUP1:=MA(C,5);
GUP2:=MA(C,10);
GUP3:=MA(C,30);
GUP4:=SMA(MAX(CLOSE-REF(CLOSE,1),0),17,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),17,1)*100;
GUP5:=BARSLAST(CROSS(GUP1,GUP2));
GUP6:=BARSLAST(CROSS(GUP1,GUP3));
GUP7:=BARSLAST(CROSS(GUP2,GUP3));
GUP8:=GUP5>=GUP6 AND GUP6>GUP7 AND GUP5-GUP7<M;
GUP9:=COUNT(CROSS(GUP1,GUP2),GUP5+1)=1 AND COUNT(CROSS(GUP1,GUP3),GUP5+1)=1 AND CROSS(GUP2,GUP3) AND GUP1>GUP2 AND GUP2>GUP3;
建仓:=GUP8 AND GUP9,COLORCCCCCC;
GUP11:=COUNT(建仓,BARSLAST(建仓)+1)=1 AND COUNT(CROSS(GUP3,GUP1),BARSLAST(建仓)+1)=0;
回踩OW<=GUP3 AND CLOSE>GUP3 AND GUP11 AND BARSLAST(建仓)>0,COLORLIRED;
|