原理:
填充背景
VAR1赋值:1日前的(最低价+开盘价+收盘价+最高价)/4
VAR2赋值:最低价-VAR1的绝对值的13日[1日权重]移动平均/最低价-VAR1和0的较大值的10日[1日权重]移动平均
VAR3赋值:VAR2的10日指数移动平均
VAR4赋值:33日内最低价的最低值
VAR5赋值:如果最低价<=VAR4,返回VAR3,否则返回0的3日指数移动平均
输出主力进场:如果VAR5>1日前的VAR5,返回VAR5,否则返回0,画红色,NODRAW
当满足条件VAR5>1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLOR000055
当满足条件VAR5>1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为2.3,0不为0则画空心柱.,COLOR000077
当满足条件VAR5>1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为2.1,0不为0则画空心柱.,COLOR000099
当满足条件VAR5>1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为1.3,0不为0则画空心柱.,COLOR0000BB
当满足条件VAR5>1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR0000DD
当满足条件VAR5>1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR0000FF
输出拉升:如果VAR5<1日前的VAR5,返回VAR5,否则返回0,画绿色,NODRAW
当满足条件VAR5<1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLOR005500
当满足条件VAR5<1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为2.3,0不为0则画空心柱.,COLOR007700
当满足条件VAR5<1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为2.1,0不为0则画空心柱.,COLOR009900
当满足条件VAR5<1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为1.3,0不为0则画空心柱.,COLOR00BB00
当满足条件VAR5<1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR00DD00
当满足条件VAR5<1日前的VAR5时,在0和VAR5位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR00FF00
A1赋值:收盘价的12日指数移动平均-收盘价的25日指数移动平均
A2赋值:A1的6日指数移动平均
获利回吐赋值:(A2>=0)*A2,画白色,线宽为1
大黑马赋值:(A2<0)*A2,COLORD4FF7F,线宽为1
坚绝做空赋值:(A1<0)*A1,COLORB00058,线宽为1
买入持股赋值:(A1>=0)*A1,画红色,线宽为1
当满足条件A2>=0时,在A2和0位置之间画柱状线,宽度为3,0不为0则画空心柱.,画白色
当满足条件A2<0时,在A2和0位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLORD4FF7F
当满足条件A1<0时,在A1和0位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLORB00058
当满足条件A1>=0时,在A1和0位置之间画柱状线,宽度为3,0不为0则画空心柱.,画红色
VAR8赋值:成交量(手)>2*成交量(手)的30日简单移动平均
VAR9赋值:"DMI的ADX"(12,6)
VARA赋值:"DMI的ADXR"(12,6)
VARB赋值:收盘价>收盘价的30日简单移动平均 AND 收盘价<收盘价的30日简单移动平均*1.04
VARC赋值:收盘价的30日简单移动平均>1日前的收盘价的30日简单移动平均
VARD赋值:上次收盘价的5日简单移动平均上穿收盘价的10日简单移动平均距今天数<上次收盘价的10日简单移动平均上穿收盘价的5日简单移动平均距今天数
VARF赋值:收盘价15%之字转向的前1个波谷位置<4
VAR10赋值:收盘价的30日指数移动平均>2日前的收盘价的30日指数移动平均
VAR11赋值:如果VARF=1,返回50,否则返回0
多空赋值:(收盘价-(2*收盘价+最高价+最低价)/4的30日简单移动平均)/(2*收盘价+最高价+最低价)/4的30日简单移动平均*100的3日指数移动平均,画白色
0,画红色
当满足条件VARF=1的5日过滤AND多空<-10时,在80和0位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLORF00FF0
当满足条件VARF=1的5日过滤时,在60和0位置之间画柱状线,宽度为3,0不为0则画空心柱.,画黄色
输出周J1:"KDJ的J[取周线数据]"(9,3,3)的5日简单移动平均,画绿色,线宽为2
20,画洋红色,线宽为1
80,画绿色
当满足条件周J1上穿20时,在20位置画1号图标
当满足条件周J1上穿20时,在15位置书写文字,画红色
当满足条件周J1上穿80时,在70位置书写文字,画黄色
N1赋值:9
N2赋值:5
MTM赋值:收盘价-1日前的收盘价
输出主力轨迹:100*MTM的N1日指数移动平均的N1日指数移动平均/MTM的绝对值的N1日指数移动平均的N1日指数移动平均,画白色
输出MAZL:主力轨迹的N2日简单移动平均,画黄色
VAR1X赋值:1日前的(最低价+开盘价+收盘价+最高价)/4
VAR2X赋值:最低价-VAR1X的绝对值的13日[1日权重]移动平均/最低价-VAR1X和0的较大值的10日[1日权重]移动平均
VAR3X赋值:VAR2X的10日指数移动平均
VAR4X赋值:33日内最低价的最低值
VAR5X赋值:如果最低价<=VAR4X,返回VAR3X,否则返回0的3日指数移动平均
输出主力进场X:如果VAR5X>1日前的VAR5X,返回VAR5X,否则返回0,画红色,NODRAW
当满足条件VAR5X>1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLOR000055
当满足条件VAR5X>1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为2.3,0不为0则画空心柱.,COLOR000077
当满足条件VAR5X>1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为2.1,0不为0则画空心柱.,COLOR000099
当满足条件VAR5X>1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为1.3,0不为0则画空心柱.,COLOR0000BB
当满足条件VAR5X>1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR0000DD
当满足条件VAR5X>1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR0000FF
输出洗盘:如果VAR5X<1日前的VAR5X,返回VAR5X,否则返回0,COLOR000079,NODRAW
当满足条件VAR5X<1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLOR000079
当满足条件VAR5X<1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为2.3,0不为0则画空心柱.,COLOR000093
当满足条件VAR5X<1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为2.1,0不为0则画空心柱.,COLOR0000C6
当满足条件VAR5X<1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为1.3,0不为0则画空心柱.,COLOR4A4AFF
当满足条件VAR5X<1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR7D7DFF
当满足条件VAR5X<1日前的VAR5X时,在0和VAR5X位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLORAAAAFF
VAR21赋值:最高价-VAR1X的绝对值的13日[1日权重]移动平均/最高价-VAR1X和0的较小值的10日[1日权重]移动平均
VAR31赋值:VAR21的10日指数移动平均
VAR41赋值:33日内最高价的最高值
VAR51赋值:如果最高价>=VAR41,返回VAR31,否则返回0的3日指数移动平均
输出主力拉高:如果VAR51<1日前的VAR51,返回VAR51,否则返回0,画黄色,NODRAW
当满足条件VAR51<1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLOR005555
当满足条件VAR51<1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为2.3,0不为0则画空心柱.,COLOR007777
当满足条件VAR51<1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为2.1,0不为0则画空心柱.,COLOR009999
当满足条件VAR51<1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为1.3,0不为0则画空心柱.,COLOR11BBBB
当满足条件VAR51<1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR33DDDD
当满足条件VAR51<1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLOR55FFFF
输出出货:如果VAR51>1日前的VAR51,返回VAR51,否则返回0,画青色,NODRAW
当满足条件VAR51>1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为3,0不为0则画空心柱.,画青色
当满足条件VAR51>1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为3,0不为0则画空心柱.,COLOR555555
当满足条件VAR51>1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为2.3,0不为0则画空心柱.,COLOR777777
当满足条件VAR51>1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为2.1,0不为0则画空心柱.,COLOR999999
当满足条件VAR51>1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为1.3,0不为0则画空心柱.,COLORBBBBBB
当满足条件VAR51>1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLORDDDDDD
当满足条件VAR51>1日前的VAR51时,在0和VAR51位置之间画柱状线,宽度为0.3,0不为0则画空心柱.,COLORFFFFFF
源码:
DRAWGBK(O>C,RGB(48,41,124),RGB(0,0,0),0,'1',0);
VAR1:=REF((LOW+OPEN+CLOSE+HIGH)/4,1);
VAR2:=SMA(ABS(LOW-VAR1),13,1)/SMA(MAX(LOW-VAR1,0),10,1);
VAR3:=EMA(VAR2,10);
VAR4:=LLV(LOW,33);
VAR5:=EMA(IF(LOW<=VAR4,VAR3,0),3);
主力进场:IF(VAR5>REF(VAR5,1),VAR5,0),COLORRED,NODRAW;
STICKLINE(VAR5>REF(VAR5,1),0,VAR5,3,0 ),COLOR000055;
STICKLINE(VAR5>REF(VAR5,1),0,VAR5,2.3,0 ),COLOR000077;
STICKLINE(VAR5>REF(VAR5,1),0,VAR5,2.1,0 ),COLOR000099;
STICKLINE(VAR5>REF(VAR5,1),0,VAR5,1.3,0 ),COLOR0000BB;
STICKLINE(VAR5>REF(VAR5,1),0,VAR5,0.3,0 ),COLOR0000DD;
STICKLINE(VAR5>REF(VAR5,1),0,VAR5,0.3,0 ),COLOR0000FF;
拉升:IF(VAR5<REF(VAR5,1),VAR5,0),COLORGREEN,NODRAW;
STICKLINE(VAR5<REF(VAR5,1),0,VAR5,3,0),COLOR005500;
STICKLINE(VAR5<REF(VAR5,1),0,VAR5,2.3,0),COLOR007700;
STICKLINE(VAR5<REF(VAR5,1),0,VAR5,2.1,0),COLOR009900;
STICKLINE(VAR5<REF(VAR5,1),0,VAR5,1.3,0),COLOR00BB00;
STICKLINE(VAR5<REF(VAR5,1),0,VAR5,0.3,0),COLOR00DD00;
STICKLINE(VAR5<REF(VAR5,1),0,VAR5,0.3,0),COLOR00FF00;
{黑马}
A1:=EMA(C,12)-EMA(C,25);
A2:=EMA(A1,6);
获利回吐:=(A2>=0)*A2,COLORWHITE,LINETHICK1;
大黑马:=(A2<0)*A2,COLORD4FF7F,LINETHICK1;
坚绝做空:=(A1<0)*A1,COLORB00058,LINETHICK1;
买入持股:=(A1>=0)*A1,COLORRED,LINETHICK1;
STICKLINE(A2>=0,A2,0,3,0),COLORWHITE;
STICKLINE(A2<0,A2,0,3,0),COLORD4FF7F;
STICKLINE(A1<0,A1,0,3,0),COLORB00058;
STICKLINE(A1>=0,A1,0,3,0),COLORRED;
VAR8:=VOL>2*MA(VOL,30);
VAR9:="DMI.ADX"(12,6);
VARA:="DMI.ADXR"(12,6);
VARB:=CLOSE>MA(CLOSE,30) AND CLOSE<MA(CLOSE,30)*1.04;
VARC:=MA(CLOSE,30)>REF(MA(CLOSE,30),1);
VARD:=BARSLAST(CROSS(MA(CLOSE,5),MA(CLOSE,10)))<BARSLAST(CROSS(MA(CLOSE,10),MA(CLOSE,5)));
VARF:=TROUGHBARS(3,15,1)<4;
VAR10:=EMA(CLOSE,30)>REF(EMA(CLOSE,30),2);
VAR11:=IF(VARF=1,50,0);
多空:=EMA((CLOSE-MA((2*CLOSE+HIGH+LOW)/4,30))/MA((2*CLOSE+HIGH+LOW)/4,30)*100,3),COLORWHITE;0,COLORRED;
STICKLINE(FILTER(VARF=1,5) AND 多空<-10,80,0,3,0),COLORF00FF0;
STICKLINE(FILTER(VARF=1,5),60,0,3,0),COLORYELLOW;
{DRAWTEXT(FILTER(VARF=1,3),25,'黑马'),COLORRED ;
{STICKLINE(多空<-10,0,多空,0.85,0),COLORYELLOW;
STICKLINE(多空>10,0,多空,0.95,0),COLORRED;};
周J1:MA("KDJ.J#WEEK"(9,3,3) ,5),COLORGREEN,LINETHICK2;
20,COLORMAGENTA,LINETHICK1;
80,COLORGREEN;
DRAWICON(CROSS(周J1,20),20,1);
DRAWTEXT(CROSS(周J1,20),15,'++抄'),COLORRED;
DRAWTEXT(CROSS(周J1,80),70,'=追'),COLORYELLOW;
{STICKLINE(周J1<0,周J1,0,5,0),COLORLIRED;
STICKLINE(CROSS(周J1,0),0,-50,3,0),COLORMAGENTA;
DRAWTEXT(CROSS(周J1,0),-35,'———底部'),COLORMAGENTA;}
{抓牛黑马
VAR1000:=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);
VAR2000:=(CLOSE-LLV(LOW,26))/(HHV(HIGH,26)-LLV(LOW,26))*100;
VAR3000:=SMA(SMA(VAR2000,3,1),3,1);
VAR4000:=EMA(VAR3000,5);
VAR5000:=LLV(LOW,26);
VAR6000:=HHV(HIGH,34);
VAR7000:=EMA((CLOSE-VAR5000)/(VAR6000-VAR5000)*4,4)*25;
{撞坷状?=IF(CROSS(VAR4000,10) AND VAR4000>10,50,0),STICK,COLORYELLOW,LINETHICK3;0,STICK,COLOR000000,LINETHICK3;
建仓区: IF((VAR7000<10),20,0), LINETHICK2,COLOR00CCFF ;
派发区: IF((VAR7000>90),80,100), LINETHICK2 ,COLORF00FF0;};
N1:=9;
N2:=5;
MTM:=C-REF(C,1);
主力轨迹:100*EMA(EMA(MTM,N1),N1)/EMA(EMA(ABS(MTM),N1),N1),COLORWHITE;
MAZL:MA(主力轨迹,N2),COLORYELLOW;
VAR1X:=REF((LOW+OPEN+CLOSE+HIGH)/4,1);
VAR2X:=SMA(ABS(LOW-VAR1X),13,1)/SMA(MAX(LOW-VAR1X,0),10,1);
VAR3X:=EMA(VAR2X,10);
VAR4X:=LLV(LOW,33);
VAR5X:=EMA(IF(LOW<=VAR4X,VAR3X,0),3);
主力进场X:IF(VAR5X>REF(VAR5X,1),VAR5X,0),COLORRED,NODRAW;
STICKLINE(VAR5X>REF(VAR5X,1),0,VAR5X,3,0 ),COLOR000055;
STICKLINE(VAR5X>REF(VAR5X,1),0,VAR5X,2.3,0 ),COLOR000077;
STICKLINE(VAR5X>REF(VAR5X,1),0,VAR5X,2.1,0 ),COLOR000099;
STICKLINE(VAR5X>REF(VAR5X,1),0,VAR5X,1.3,0 ),COLOR0000BB;
STICKLINE(VAR5X>REF(VAR5X,1),0,VAR5X,0.3,0 ),COLOR0000DD;
STICKLINE(VAR5X>REF(VAR5X,1),0,VAR5X,0.3,0 ),COLOR0000FF;
洗盘:IF(VAR5X<REF(VAR5X,1),VAR5X,0),COLOR000079,NODRAW;
STICKLINE(VAR5X<REF(VAR5X,1),0,VAR5X,3,0),COLOR000079;
STICKLINE(VAR5X<REF(VAR5X,1),0,VAR5X,2.3,0),COLOR000093;
STICKLINE(VAR5X<REF(VAR5X,1),0,VAR5X,2.1,0),COLOR0000C6;
STICKLINE(VAR5X<REF(VAR5X,1),0,VAR5X,1.3,0),COLOR4A4AFF;
STICKLINE(VAR5X<REF(VAR5X,1),0,VAR5X,0.3,0),COLOR7D7DFF;
STICKLINE(VAR5X<REF(VAR5X,1),0,VAR5X,0.3,0),COLORAAAAFF;
VAR21:=SMA(ABS(HIGH-VAR1X),13,1)/SMA(MIN(HIGH-VAR1X,0),10,1);
VAR31:=EMA(VAR21,10);
VAR41:=HHV(HIGH,33);
VAR51:=EMA(IF(HIGH>=VAR41,VAR31,0),3);
主力拉高:IF(VAR51<REF(VAR51,1),VAR51,0),COLORYELLOW,NODRAW;
STICKLINE(VAR51<REF(VAR51,1),0,VAR51,3,0),COLOR005555;
STICKLINE(VAR51<REF(VAR51,1),0,VAR51,2.3,0),COLOR007777;
STICKLINE(VAR51<REF(VAR51,1),0,VAR51,2.1,0),COLOR009999;
STICKLINE(VAR51<REF(VAR51,1),0,VAR51,1.3,0),COLOR11BBBB;
STICKLINE(VAR51<REF(VAR51,1),0,VAR51,0.3,0),COLOR33DDDD;
STICKLINE(VAR51<REF(VAR51,1),0,VAR51,0.3,0),COLOR55FFFF;
出货:IF(VAR51>REF(VAR51,1),VAR51,0),COLORCYAN,NODRAW;
STICKLINE(VAR51>REF(VAR51,1),0,VAR51,3,0 ),COLORCYAN;
STICKLINE(VAR51>REF(VAR51,1),0,VAR51,3,0),COLOR555555;
STICKLINE(VAR51>REF(VAR51,1),0,VAR51,2.3,0),COLOR777777;
STICKLINE(VAR51>REF(VAR51,1),0,VAR51,2.1,0),COLOR999999;
STICKLINE(VAR51>REF(VAR51,1),0,VAR51,1.3,0),COLORBBBBBB;
STICKLINE(VAR51>REF(VAR51,1),0,VAR51,0.3,0),COLORDDDDDD;
STICKLINE(VAR51>REF(VAR51,1),0,VAR51,0.3,0),COLORFFFFFF;
如有需要
,请加QQ:88652583 或微信: 88652583