主图
N:=34;
M1:=3;
M2:=3;
DRAWGBK(C>0,RGB(0,10,10),RGB(88,0,0),0,'0',0);
DRAWGBK(C>0,RGB(40,120,20),RGB(00,00,00),0,'0',1);
DRAWGBK(C>0,RGB(80,100,120),RGB(00,00,00),0,'0',1);
Z111:=STRCAT(HYBLOCK,'----');
Z211:=STRCAT(Z111,FGBLOCK);
Z311:=STRCAT(Z211,DYBLOCK);
Z411:=STRCAT(Z311,'----');
DRAWTEXT_FIX(1,0.00,0.00,0,'【主题概念】')COLORCYAN;
DRAWTEXT_FIX(ISLASTBAR,0.09,0.00,0,STRCAT(Z411,GNBLOCK)),COLORCYAN;
NW1:=CLOSE/REF(CLOSE,1)>1.03;
NW2:=EMA(CLOSE,9);
NW3:=EMA(NW2*1.13,5);
NW4:=CLOSE>=OPEN;
NW5:=EMA(NW2*1.12,5);
NW6:=EMA(NW2*1.11,5);
NW7:=CROSS(CLOSE,NW6);
NW8:=CROSS(CLOSE,NW3);
NW9:=CROSS(CLOSE,NW5);
NW10:=(NW8 OR NW9 OR NW7 AND NW4 AND NW1);
NW11:=HHV(HHV(LOW,14),60);{BB}
NW12:=HHV(MA((L+H+C)/3,8),60),COLORFF00FF;{X}
NW13:=EMA(EMA(NW12,14)+2*STD(NW11,14),4),COLORAAAAAA;
NW14:=C>NW12 AND C>NW13 AND NW10;
纲一:EMA(EMA(NW11,16)-2*STD(NW11,16),3),COLORAAAAAA;
纲二:EMA(EMA(NW11,14)+2*STD(NW11,14),8),COLORAAAAAA;
STICKLINE(纲一>0 ,纲一 ,纲二 ,0 ,0 ),COLOR555555;
DRAWTEXT_FIX(CLOSE>0,0,0.06,0,'【仓位管理】')COLORYELLOW;
DRAWTEXT_FIX(CLOSE>0,0.09,0.06,0,'红色持仓,黄棕色警告,青色空仓,黄色芯涨停,蓝色芯跌停,粉上影线涨停后回落,蓝下影线跌停后回升,K线进网小心,蓝色忽略 ')COLORFF9900;
RSV:=(CLOSE-LLV(LOW,N))/(HHV(HIGH,N)-LLV(LOW,N))*100;
K:=SMA(RSV,M1,1);
D:=SMA(K,M2,1);
持仓段:=IF(D>LLV(D,2),1,IF(D<HHV(D,2),0,DRAWNULL)),NODRAW;
STICKLINE(持仓段=1 AND CLOSE>=OPEN,OPEN,CLOSE,3,1),COLORRED;
STICKLINE(持仓段=1 AND CLOSE>=OPEN,CLOSE,HIGH,0,1),COLORRED;
STICKLINE(持仓段=1 AND CLOSE>=OPEN,LOW,OPEN,0,1),COLORRED;
STICKLINE(持仓段=1 AND CLOSE<=OPEN,OPEN,CLOSE,3,0),COLORRED;
STICKLINE(持仓段=1 AND CLOSE<=OPEN,HIGH,LOW,0,0),COLORRED;
STICKLINE(持仓段=1 AND K<REF(K,1) AND CLOSE>=OPEN,OPEN,CLOSE,3,1),COLOR3399CC;
STICKLINE(持仓段=1 AND K<REF(K,1) AND CLOSE>=OPEN,CLOSE,HIGH,0,1),COLOR3399CC;
STICKLINE(持仓段=1 AND K<REF(K,1) AND CLOSE>=OPEN,LOW,OPEN,0,1),COLOR3399CC;
STICKLINE(持仓段=1 AND K<REF(K,1) AND CLOSE<=OPEN,OPEN,CLOSE,3,0),COLOR3399CC;
STICKLINE(持仓段=1 AND K<REF(K,1) AND CLOSE<=OPEN,HIGH,LOW,0,0),COLOR3399CC;
STICKLINE(持仓段=0 AND CLOSE>=OPEN,CLOSE,OPEN,3,1),COLORCYAN;
STICKLINE(持仓段=0 AND CLOSE>=OPEN,CLOSE,HIGH,0,1),COLORCYAN;
STICKLINE(持仓段=0 AND CLOSE>=OPEN,LOW,OPEN,0,1),COLORCYAN;
STICKLINE(持仓段=0 AND CLOSE<=OPEN,CLOSE,OPEN,3,0),COLORCYAN;
STICKLINE(持仓段=0 AND CLOSE<=OPEN,HIGH,LOW,0,0),COLORCYAN;
NGH:= C<纲一;
STICKLINE(NGH,O,C,3,0),COLORFF9900;
STICKLINE(NGH,L,H,0,0),COLORFF9900;
BK:=IF(INBLOCK('科创板'),0.2,IF(INBLOCK('创业板'),0.2,IF(INBLOCK('ST板块'),0.05,0.1)));
XA_1:=IF(DATE<=1200823,1,0);
STICKLINE((C>=ZTPRICE(REF(CLOSE,1),0.1) AND C=H) AND XA_1=1,O,C,2.7,0),COLORRED;
STICKLINE((C<=DTPRICE(REF(CLOSE,1),0.1) AND C=L) AND XA_1=1,O,C,2.7,0),COLORBLUE;
STICKLINE((C>=ZTPRICE(REF(C,1),BK) AND C=H),O,C,1,0),COLORYELLOW;
STICKLINE((C<=DTPRICE(REF(C,1),BK) AND C=L),O,C,1,0),COLORBLUE;
STICKLINE((H>=ZTPRICE(REF(C,1),BK) AND C<H) OR (H>=ZTPRICE(REF(CLOSE,1),0.1) AND C<H AND XA_1=1),H,MAX(C,O),0.2,0),COLORMAGENTA;
STICKLINE((L<=DTPRICE(REF(C,1),BK) AND C>L) OR (L<=DTPRICE(REF(CLOSE,1),0.1) AND C>L AND XA_1=1),L,MIN(C,O),0.2,0),COLORBLUE;
条件1:= V<REF(V,1) AND REF(V,1)=HHV(V,0);
TS20:=BARSLAST(条件1)+1;
高20:=REF(H,TS20);
低20:=REF(L,TS20);
STICKLINE(高20,高20,高20,16,0),COLORRED,LINETHICK2;
STICKLINE(低20,低20,低20,8,0),COLORGREEN,LINETHICK1;
{DRAWTEXT_FIX(1,0.0,0.850,0,'个股亮点:')COLORLIGREEN;} {同花顺}
{DRAWTEXT_FIX(1,0.04,0.850,0,EXTERNSTR(0,26))COLORFF00FF;
DRAWTEXT_FIX(1,0.0,0.900,0,'热点解读:')COLORFF00FF;
DRAWTEXT_FIX(1,0.04,0.900,0,EXTERNSTR(0,27))COLORYELLOW;} {上市公司主营};
{DRAWTEXT_FIX(1,0.0,0.991,0,'全部概念:')COLORYELLOW;
DRAWTEXT_FIX(1,0.04,0.991,0,EXTERNSTR(0,36))COLORLIGREEN;};
金牛金准抄底副图
TDXSTEP303:DRAWGBK(OPEN<CLOSE,RGB(160,24,240),RGB(56,88,15),0,1,0);
VAR1:=SUM(IF(CLOSE>REF(CLOSE,1),VOL,IF(CLOSE<REF(CLOSE,1),0-VOL,0)),0);
VAR2:=SUMBARS(VOL,CAPITAL);
VAR3:=IF(CLOSE>LLV(CLOSE,VAR2),1,0-1)*IF(VAR2,1,0-1);
VAR4:=IF(VAR3=0-1,1,0);
VAR5:=COUNT(VAR4=1,8)>3;
VAR6:=SUM(AMOUNT,13)/(AMOUNT/VOL/100)/100;
VAR7:=DMA((OPEN+HIGH+LOW+CLOSE)/4,VOL/VAR6);
VAR8:=(CLOSE-VAR7)/VAR7*100<0-17;
VAR9:=(CLOSE-MIN(REF(CLOSE,5)*0.83,REF(CLOSE,21)*0.72))/CLOSE<0.05;
金牛:=VAR8 AND VAR9 AND VAR5;
金牛精确:=金牛>0 AND REF(金牛,1)=0;
金牛抄底:=COUNT(金牛精确,5) AND CLOSE>OPEN;
精确抄底:COUNT(金牛抄底,5)=1 AND 金牛抄底;
TDXSTEP304:STICKLINE(IF(精确抄底,(-120),0),12,0,4,0),COLOR000088;
TDXSTEP305:STICKLINE(IF(精确抄底,(-120),0),12,0,3,0),COLOR0000AA;
TDXSTEP306:STICKLINE(IF(精确抄底,(-120),0),12,0,2,0),COLOR0000CC;
TDXSTEP307:STICKLINE(IF(精确抄底,(-120),0),12,0,1.4,0),COLOR0000EE;
TDXSTEP308:STICKLINE(IF(精确抄底,(-120),0),12,0,0.9,0),COLOR0000EE;
TDXSTEP309:STICKLINE(IF(精确抄底,(-120),0),12,0,0.3,0),COLORLIMAGENTA;
TDXSTEP310:STICKLINE(IF(精确抄底,(-120),0),9,0,7,0),COLOR770077;
TDXSTEP311:STICKLINE(IF(精确抄底,(-120),0),9,0,6,0),COLOR990099;
TDXSTEP312:STICKLINE(IF(精确抄底,(-120),0),9,0,5,0),COLORBB00BB;
TDXSTEP313:STICKLINE(IF(精确抄底,(-120),0),9,0,4,0),COLORDD00DD;
TDXSTEP314:STICKLINE(IF(精确抄底,(-120),0),9,0,3,0),COLORMAGENTA;
TDXSTEP315:STICKLINE(IF(精确抄底,(-120),0),9,0,2,0),COLORDD00DD;
TDXSTEP316:STICKLINE(IF(精确抄底,(-120),0),6,0,7,0),COLOR003300;
TDXSTEP317:STICKLINE(IF(精确抄底,(-120),0),6,0,6,0),COLOR005500;
TDXSTEP318:STICKLINE(IF(精确抄底,(-120),0),6,0,5,0),COLOR007700;
TDXSTEP319:STICKLINE(IF(精确抄底,(-120),0),6,0,3.5,0),COLOR009900;
TDXSTEP320:STICKLINE(IF(精确抄底,(-120),0),6,0,2,0),COLOR00CC00;
TDXSTEP321:STICKLINE(IF(精确抄底,(-120),0),3,0,7,0),COLOR666666;
TDXSTEP322:STICKLINE(IF(精确抄底,(-120),0),3,0,6,0),COLOR777777;
TDXSTEP323:STICKLINE(IF(精确抄底,(-120),0),3,0,5,0),COLOR888888;
TDXSTEP324:STICKLINE(IF(精确抄底,(-120),0),3,0,4,0),COLOR999999;
TDXSTEP325:STICKLINE(IF(精确抄底,(-120),0),3,0,3,0),COLORDDDDDD;
TDXSTEP326:STICKLINE(IF(精确抄底,(-120),0),3,0,2,0),COLORWHITE;
TDXSTEP327:STICKLINE(IF(精确抄底,(-120),0),(-3),0,7,0),COLOR000044;
TDXSTEP328:STICKLINE(IF(精确抄底,(-120),0),(-3),0,6,0),COLOR000033;
TDXSTEP329:STICKLINE(IF(精确抄底,(-120),0),(-3),0,5,0),COLOR000055;
TDXSTEP330:STICKLINE(IF(精确抄底,(-120),0),(-3),0,4,0),COLOR000077;
TDXSTEP331:STICKLINE(IF(精确抄底,(-120),0),(-3),0,3,0),COLOR000099;
TDXSTEP332:STICKLINE(IF(精确抄底,(-120),0),(-3),0,2,0),COLORLIMAGENTA;
TDXSTEP333:DRAWTEXT(精确抄底,10.5,76),COLORYELLOW;
TDXSTEP334:DRAWTEXT(精确抄底,7.5,77),COLORYELLOW;
TDXSTEP335:DRAWTEXT(精确抄底,4.5,78),COLORRED;
TDXSTEP336:DRAWTEXT(精确抄底,1.5,79),COLORRED;
TDXSTEP337:DRAWTEXT(精确抄底,(-1.5),80),COLORYELLOW;
金牛买卖差副图
VOL,VOLSTICK;
VAR1:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));
主买:=IF(CLOSE>OPEN,VAR1*(HIGH-LOW),IF(CLOSE<OPEN,VAR1*((HIGH-OPEN)+(CLOSE-LOW)),VOL/2)),COLORRED,NODRAW;
主卖:=IF(CLOSE>OPEN,0-VAR1*((HIGH-CLOSE)+(OPEN-LOW)),IF(CLOSE<OPEN,0-VAR1*(HIGH-LOW),0-VOL/2)),COLOR00FF00,NODRAW;
【买卖差】:主买+主卖,NODRAW,COLOR0000FF;
STICKLINE(C>O,0,VOL,3,1),COLOR0000AA;
STICKLINE(C<O,0,VOL,3,1),COLOR00AA00;
STICKLINE(【买卖差】>0,0,【买卖差】,1,0),COLOR0000FF;
STICKLINE(【买卖差】<0,0,-【买卖差】,1,0),COLOR00FF00;
金牛操盘结构
黄线上穿白线,且有黄柱有一定机率会大涨,可以择机买入。
若黄线与白线一直平行,说明机构高度控盘,一旦突破成妖机率非常大。
机构一波拉升后,如果黄色柱体消失,最好止盈离场 。
RA:=MAX(O,C);
RB:=MIN(O,C);
RC:=REF(HHV(H,2),1);
RD:=REF(LLV(L,2),1);
T1:=IF(RA>RC,1,IF(RB<RD,-1,0));
T2:=BARSLAST(T1=0);
TH:=REF(REF(H,BARSLAST(T1=1)),T2);
TL:=REF(REF(L,BARSLAST(T1=-1)),T2);
TA:=IF(T1=1,IF(RA>TH,1,0),IF(T1=-1,IF(RB<TL,-1,0),0));
T3:=BARSLAST(TA=-1);
T4:=BARSLAST(TA=1);
RE:=REF(COUNT(CROSS(TA,-0.5),T4),T3);
RF:=COUNT(CROSS(TA,0.5),T3);
TB:=IF(TA=1,IF(RF=1,IF(RE>0,1,0),0),0);
NOTEXT1:=VALUEWHEN(TB,REF(REF(H,T4),T3)),COLORGREEN,LINETHICK2;{水平线};
乖离:=100*ABS(C-NOTEXT1)/NOTEXT1<10;
DIF:=EMA(CLOSE,18)-EMA(CLOSE,40);
DEA:=EMA(DIF,3);
MACD:=(DIF-DEA)*2;
MD:=MACD#DAY;
MW:=MACD#WEEK;
MM:=MACD#MONTH;
MS:=MACD#SEASON;
NOTEXTMACD1:EMA((MD+MW*7+MM*31+MS*94)/133,5) LINETHICK2 COLORYELLOW NODRAW;
STICKLINE(NOTEXTMACD1>0,NOTEXTMACD1,0,3,1),COLORRED;
STICKLINE(NOTEXTMACD1<0,NOTEXTMACD1,0,3,1),COLORCYAN;
NOTEXTMACD120:REF(NOTEXTMACD1/2,BARSLAST(NOTEXTMACD1=HHV(NOTEXTMACD1,120))),COLORRED,LINETHICK1;
NOTEXTMACD250:REF(NOTEXTMACD1/2,BARSLAST(NOTEXTMACD1=HHV(NOTEXTMACD1,250))),COLORWHITE,LINETHICK1;
XG:=NOT(REF(NOTEXTMACD120,1)=NOTEXTMACD120);
STICKLINE(XG,0,NOTEXTMACD1,2,0),COLORYELLOW;{画金柱 120}
STICKLINE(NOTEXTMACD1>=NOTEXTMACD250,NOTEXTMACD250,NOTEXTMACD1,2,0),COLORMAGENTA; {画粉柱 250}
大行情:=NOT(REF(NOTEXTMACD120,1)=REF(NOTEXTMACD250,1)) AND NOTEXTMACD120=NOTEXTMACD250 AND C>NOTEXT1 AND 乖离;
NOTEXT前高:IF(HHVBARS(MACD ,90) ,REF(MACD ,HHVBARS(MACD,90) ),MACD )COLORYELLOW,LINETHICK2;
NOTEXT3:IF(NOTEXT前高>REF(NOTEXT前高,1),NOTEXT前高,DRAWNULL),COLORMAGENTA,LINETHICK4;
NOTEXT4:IF(NOTEXT前高<REF(NOTEXT前高,1),NOTEXT前高,DRAWNULL),COLORGREEN,LINETHICK4;
DRAWTEXT(大行情 AND NOTEXT前高>NOTEXTMACD250,-0.01,'↖大牛启动'),COLORYELLOW;