箱底 箱顶 短趋势线 中趋势线 压力位 支撑位
本指标有未来函数
发现未来函数DVOL!
发现未来函数DCLOSE!
发现未来函数TROUGH!
发现未来函数PEAK!
{金手指}
MA1:MA(CLOSE,5);
MA2:MA(CLOSE,10);
MA3:MA(CLOSE,25);
MA4:MA(CLOSE,60);
MA5:MA(CLOSE,610);
DRAWTEXT_FIX(1,0.00,0,0,HYBLOCK)COLOR0080FF;
DRAWTEXT_FIX(1,0.14,0,0,DYBLOCK)COLOR00FFFF;
DRAWTEXT_FIX(1,0.00,0.06,0,EXTERNSTR(0,1))COLOR0000FF;
DRAWTEXT_FIX(1,0.00,0.12,0,EXTERNSTR(0,2))COLORFF00FF;
DRAWTEXT_FIX(1,0.00,0.18,0,EXTERNSTR(0,3))COLORFF88FF;
DRAWTEXT_FIX(1,0.00,0.24,0,EXTERNSTR(0,5)),COLORLICYAN;
箱底:=TROUGH(CLOSE,10,1)*1.02,COLOR008888,LINETHICK2;
价低箱底:=COUNT(L<箱底,3);
底箱:=TROUGH(CLOSE,10,1)*1.05,COLOR008888,LINETHICK1;
DRAWTEXT(价低箱底>=1 AND 箱底
STICKLINE(金手指,OPEN,CLOSE,1.6,0),COLOR00AAAA;
STICKLINE(金手指,OPEN,CLOSE,0.8,0),COLOR00CCCC;
STICKLINE(金手指,OPEN,CLOSE,0.2,0),COLOR00FFFF;
止跌:=(REF(EVERY(C
VAR1N:=MA(CLOSE,5),;
VAR2N:=MA(CLOSE,10);
VAR3N:=(VAR1N-CLOSE)/CLOSE>3/100;
VAR4N:=(VAR2N-VAR1N)/VAR1N>0.03;
VAR5N:=LLV(CLOSE,30)=LLV(CLOSE,120);
底部:=VAR3N AND VAR4N AND VAR5N;
STICKLINE(BARSLAST(底部)<=2 AND 止跌,OPEN,CLOSE,2.0,0),COLORFF0066;
短趋势线:=MA(CLOSE,13),COLORRED,LINETHICK3;
中线:=MA(CLOSE,33),LINETHICK1;
中趋势线:=MA(CLOSE,55),LINETHICK1,COLORGRAY;
上极限:=((C-REF(MA(CLOSE,20),1))/20+短趋势线)*1.20;
DRAWTEXT(CROSS(短趋势线,C) AND INDEXC>MA(INDEXC,13) AND 短趋势线>REF(短趋势线 ,1) AND V中趋势线 ,L*0.985,'买入'),COLORRED;
箱顶:=PEAK(CLOSE,10,1)*1.001,COLORFF4400;
RESV:=(CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*100;
KEE:=SMA(RESV,3,1);
DEE:=SMA(KEE,3,1);
JEE:=3*KEE-2*DEE;
RSV24:=(CLOSE-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))*100;
K24:=SMA(RSV24,3,1);
D24:=SMA(K24,3,1);
J24:=3*K24-2*D24;
压力位:=IF(CROSS(J24,JEE),H,REF(H,BARSLAST(CROSS(J24,JEE)))),COLOR669900,LINETHICK1;
支撑位:=IF(CROSS(JEE,J24),L,REF(L,BARSLAST(CROSS(JEE,J24)))),COLORCE6700,LINETHICK2;
追涨:=压力位<箱顶 AND CROSS(C,箱顶);
DRAWTEXT(压力位<箱顶 AND CROSS(C,箱顶),L,'追涨'),COLORCC8868;
A1:=REF(V,1);A2:=DVOL;A3:=A2/A1;
LNX:=A3-REF(A3,1),COLOR00CCCC,LINETHICK1;
E1:=REF(C,1);E2:=DCLOSE;E3:=(E2-E1)/E1*100;
QMX:=E3-REF(E3,1),COLOR00CCCC,LINETHICK2;
XG:=CROSS(LNX,500) AND CROSS(QMX,10);
DRAWTEXT(XG=1,L*0.985,'金手指'),COLORCC8868;
DRAWICON(XG=1,L*0.99,11);
2、MACD神器抓妖股
这个公式自用了很久,一直觉得很不错,看图说话。
进场的点位还是很准的(金叉买进,其他的自己研究。),
至于什么时候出来,那需要每个人自己把握了( 顶尖 财经 股票学院: )
{MACD神器抓妖股}
RSV:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
K:SMA(RSV,3,1),LINETHICK2,COLORWHITE;
D:SMA(K,3,1),LINETHICK2,COLOR00DDDD;
J:3*K-2*D,LINETHICK2,COLOR800080;
DIF:EMA(CLOSE,12)-EMA(CLOSE,26),LINETHICK0,COLOR0099FF;
DEA :EMA(DIF,9),LINETHICK0,COLORD89837;
MACD:2*(DIF-DEA),COLORFF9999,LINETHICK0;
YLZC:=IF(CLOSE=INDEXC,(INDEXC+INDEXH+INDEXL+INDEXO)/4,AMOUNT/(VOL+0.01)/100);
阻价:=IF(CLOSE=INDEXC,YLZC+INDEXC-INDEXL,YLZC+(CLOSE-LOW));
支价:=IF(CLOSE=INDEXC,INDEXL+INDEXC-YLZC,LOW+(CLOSE-YLZC));
今压:REF(阻价,1),LINETHICK0,COLORAA11BB;
今撑:REF(支价,1),LINETHICK0,COLOR009900;
明压:阻价,LINETHICK0;
明撑:支价,LINETHICK0;
RSV1:=(HHV(H,9.8)-C)/(HHV(H,9.8)-LLV(L,9.8))*101;
KK:=SMA(RSV1,3,1);
DD:=SMA(KK,3,1);
JJ:=3*KK-2*DD;
买卖:=IF(JJ>=100,100,IF(JJ<=0,0,JJ));
明天买:IF(买卖=100,0-10,0),COLOR00CCCC;
明天卖:IF(买卖=0,90,100),COLOR00FF00;
KX:=250;
KH:=HHV(K,KX);
DH:=HHV(D,KX);
JH:=HHV(J,KX);
KL:=LLV(K,KX);
DL:=LLV(D,KX);
JL:=LLV(J,KX);
HKMAX:=MAX(KH,MAX(DH,JH));
LKMIN:=MIN(KL,MIN(DL,JL));
KHLB:=(HKMAX+LKMIN)/2;
KHLC:=HKMAX-LKMIN;
MHF:=HHV(DIF,KX);
MHD:=HHV(DEA,KX);
MHM:=HHV(MACD,KX);
MLF:=LLV(DIF,KX);
MLD:=LLV(DEA,KX);
MLM:=LLV(MACD,KX);
HMAX:=MAX(MHF,MAX(MHD,MHM));
LMIN:=MIN(MLF,MIN(MLD,MLM));
FHLB:=(HMAX-LMIN)/100;
FHLC:=HMAX-LMIN;
SH:=(0-FHLB)*(KHLC/FHLC)+KHLB;
DIFA:=(DIF-FHLB)*(KHLC/FHLC)+KHLB;
DEAA:=(DEA-FHLB)*(KHLC/FHLC)+KHLB;
MACDA:=(MACD-FHLB)*(KHLC/FHLC)+KHLB;
CDA:=MACD0;
CDB:=MACD>=REF(MACD,1) AND MACD>0;
CDC:=MACD>REF(MACD,1) AND MACD<0;
CDD:=MACD<=REF(MACD,1) AND MACD<0;
STICKLINE(CDA,SH,MACDA,2,0),COLOR00AAFF;{黄色段}
STICKLINE(CDB,SH,MACDA,2,0),COLOR0000AA; {红色段}
STICKLINE(CDC,SH,MACDA,2,0),COLORAA00BB;{向上粉红}
TYP:=(HIGH+LOW+CLOSE)/3;
STICKLINE(DIF>REF(DIF,1),20,20,2,0),COLORRED;
STICKLINE(DIFSTICKLINE(K>=REF(K,1) OR K>D AND DIF>REF(DIF,1),80,80,2,1),COLORRED;
STICKLINE(KMACD金叉:=CROSS(MACD,DIF) AND MACD>=(0-0.05) AND MACD<=0.02;
DRAWTEXT(MACD金叉,MACDA*0.82,'▲MACD金叉'),COLOR00FFFF;
XX:=EMA(MA(LOW,3)*0.96,30);
DIF金叉:=IF(CROSS(DIF,DEA) AND XX-REF(XX,1)>0 AND MACD>=REF(MACD,1) AND DIF<=0,1,0);
DRAWTEXT(DIF金叉=1,DIFA*1.68,'DIF金叉'),COLORCDFFBB;
低位金叉:=CROSS(DIF,DEA) AND DIF<-0.1;
DRAWTEXT(低位金叉,DEAA*0.99,'▲DIF低位金叉'),COLOR0099DD;
DIFDEA:=COUNT(CROSS(DIF,DEA),BARSLAST(DEA>=0));
二次金叉:=CROSS(DIF,DEA) AND DEA<0 AND COUNT(DIFDEA=2,21)=1;
DRAWTEXT(二次金叉,DEAA*0.99-8,'▲DIF 二次金叉'),COLORFF00FF;
A1:=BARSLAST(REF(CROSS(DIF,DEA),1));
底背离:=REF(CLOSE,A1+1)>CLOSE AND DIF>REF(DIF,A1+1) AND CROSS(DIF,DEA);
DRAWTEXT(底背离,DEAA*0.99-16,'▲DIF底背离'),COLOR0099FF;
A2:=BARSLAST(REF(CROSS(DEA,DIF),1));
顶背离:=REF(CLOSE,A2+1)
DRAWTEXT(FILTER(顶背离,5),DEAA*1.02,'▲DIF顶背离'),COLORDDAAAA;
{周金叉,死叉}
周DIF:="MACD.DIF#WEEK";
周DEA:="MACD.DEA#WEEK";
周MACD:="MACD.MACD#WEEK";
DIF周金叉:=CROSS(周DIF,周DEA);
DRAWTEXT(DIF周金叉,DEAA,'DIF周金叉'),COLOR0099FF;
DRAWTEXT(CROSS(周DEA,周DIF),DEAA+4,'▲DIF周死叉'),COLORCDFFBB;
MACD周金叉:=CROSS(周MACD,周DIF) AND 周MACD>=(0-0.05) AND 周MACD<=0.02;
DRAWTEXT(MACD周金叉,MACDA-0.03,'▲MACD周金叉'),COLOR00FFFF;
{月金叉,死叉}
月DIF:="MACD.DIF#MONTH";
月DEA:="MACD.DEA#MONTH";
DIF月金叉:=CROSS(月DIF,月DEA);
DRAWTEXT(DIF月金叉,DEAA*0.98,'★DIF月金叉'),COLOR00FFCC;
DRAWTEXT(CROSS(月DEA,月DIF),DEAA*1.02,'★DIF月死叉');
周K:="KDJ.K#WEEK"(9,3,3);
周D:="KDJ.D#WEEK"(9,3,3);
周J:="KDJ.J#WEEK"(9,3,3);
月K:="KDJ.K#MONTH"(9,3,3);
月D:="KDJ.D#MONTH"(9,3,3);
月J:="KDJ.J#MONTH"(9,3,3);
月金叉:=CROSS(月K,月D);
周金叉:=CROSS(周K,周D);
日金叉:=FILTER(CROSS(K,D) AND K<20,4);
DRAWTEXT(月金叉,月D-2,'★'),COLOR0022EE;
DRAWTEXT(月金叉,月D-2,'.KD月金叉'),COLORYELLOW;
DRAWTEXT(周金叉,周D,'★'),COLOR0022EE;
DRAWTEXT(周金叉,周D,'. KD周金叉'),COLORGREEN;
DRAWICON(日金叉,K,1);
DRAWTEXT(日金叉,D-6,'★KD低位金叉'),COLOR00CCCC;
DRAWTEXT(CROSS(周D,周K),周D*1.2,'★KD周死叉'),COLOR00DDBB;
DRAWTEXT(CROSS(月D,月K),月D,'★KD月死叉'),COLORFFFFFF;
KDB:=BARSLAST(REF(CROSS(K,D),1));
KDDB:=REF(CLOSE,KDB+1)>CLOSE AND REF(K,KDB+1)
DRAWTEXT(K底背=1,D*0.98,'★KD底背离'),COLORDDDDDD;
KDD:=BARSLAST(REF(CROSS(D,K),1));
K顶背:=REF(CLOSE,KDD+1)
DRAWTEXT(FILTER(K顶背>0,5),D+8,'★KD顶背离'),COLORFFAA22;
MD1:=MA(CLOSE,80)-MA(CLOSE,13)/3;
MD2:=MA((CLOSE-MD1)/MD1,3);
买点1:=CROSS(MD2,0) AND LOW/REF(HIGH,1)<1.012 AND J<75 AND J>REF(J,1);
MA12:=MA(CLOSE,12);
佳点:=IF(FILTER(MACD>=REF(MACD,5) AND OPEN<=REF(CLOSE,1) AND XX-REF(XX,1)>0 AND MACD<=0 AND MA12-REF(MA12,1)>=0,3) AND J<80 AND J>REF(J,1) AND D>REF(D,1) AND (DIF>=REF(DIF,1) OR DEA>=REF(DEA,1)),1,0);
DRAWTEXT(佳点=1,MACDA*0.98,'★佳点'),COLOR0099FF;
DX0:=EMA(CLOSE,2)-EMA(OPEN,5);
DX1:=IF(CROSS(DX0,MACD) AND LOW<=XX AND MACD<=(0-0.11) AND (J<20 OR K<20),1,0);
DRAWTEXT(FILTER(DX1,3),0,'★短10%'),COLOR00CC00;{短线}
MA10:=MA(CLOSE,10);
SS:=EMA(MA(HIGH,3)*1.05,30);
LQS:=IF(FILTER(0.7*(CROSS(DIF,DEA) AND CLOSE
DRAWTEXT(LQS=1,MACDA*0.98,'★量价齐上'),COLORCDFFDD;{量价齐上}
最佳点:=IF(COUNT(MD2>REF(MD2,1),3)=3 AND COUNT(MD2<0,10)=10 AND REF(MD2,3)=LLV(MD2,10) AND J<80 AND J>REF(J,1),1,0);
DRAWTEXT(最佳点=1,J,'★最佳点'),COLORFF00CC;
买点2:=REF(MD2,2)=LLV(MD2,20) AND REF(MD2,2)<0.071 AND REF(MD2,2)NOT(REF(LOW,1)>REF(HIGH,2) AND LOW>REF(HIGH,1)) AND CLOSE>REF(CLOSE,1) AND J<75 AND J>REF(J,1);
DRAWTEXT(买点1 OR 买点2,D-1,'买'),COLORFF00CC;
{预涨}
YZ:=(INTPART(SMA(RSV,3,1))+INTPART(SMA(K,3,1)))/2;
预涨:=CROSS(YZ,50) AND J<95 AND DIF>REF(DIF,1) AND LOWDRAWTEXT(预涨,D*0.6,'★预涨'),COLORA52A2A;
3、量学金城白
{公式名称: 量学金城白
公式描述: 低分辨率白底
参数数量: 5
参数1: 取值, 最小: 1, 最大: 100, 缺省: 7
参数2: N, 最小: 1, 最大: 20, 缺省: 9
参数3: M1, 最小: 1, 最大: 20, 缺省: 3
参数4: M2, 最小: 1, 最大: 20, 缺省: 3
参数5: 高量天数, 最小: 5, 最大: 999, 缺省: 8
}
{灯塔太极}
{TAIJI_A:=YEAR=2014 AND MONTH=11 AND DAY=24;
TAIJI_B:=YEAR=2014 AND MONTH=11 AND DAY=27;
TAIJI_C:=YEAR=2014 AND MONTH=7 AND DAY=22;
TAIJI_D:=YEAR=2014 AND MONTH=8 AND DAY=29;
{DATA1:=YEAR=2014 AND MONTH=8 AND DAY=19;
DATA2:=YEAR=2014 AND MONTH=8 AND DAY=22;
DATA3:=YEAR=2014 AND MONTH=8 AND DAY=21;
DATA4:=YEAR=2014 AND MONTH=8 AND DAY=20;
{O线:=DRAWLINE(DATA1,C,DATA4,REF(C,1),1),COLORMAGENTA,LINETHICK1;
A线:=DRAWLINE(DATA1,C,DATA4,H,1),COLORMAGENTA,LINETHICK1;
B线:=DRAWLINE(DATA1,C,DATA3,L,1),COLORMAGENTA,LINETHICK1;
C线:=DRAWLINE(DATA1,C,DATA2,L,1),COLORMAGENTA,LINETHICK1;
{太极当值1:=DRAWLINE(TAIJI_A,C,TAIJI_B,L,3),COLORRED,LINETHICK2;
太极当值2:=DRAWLINE(TAIJI_C,O,TAIJI_D,O,3),COLORRED,LINETHICK2;
{明日太极当值1:=太极当值1+(太极当值1-REF(太极当值1,1)),NODRAW,COLORWHITE;
明日太极当值2:=太极当值2+(太极当值2-REF(太极当值2,1)),NODRAW,COLORWHITE;}
公式规属:DRAWTEXT_FIX(ISLASTBAR,0.99,2,3,'【顶尖 财经 股票学院: 】'),COLORRED;
C22:=REF(C,1);
ZT:=IF((C-C22)*100/C22>=(10-0.01*100/C22),1,0);
LG:=TOPRANGE(VOL);
FZG:=H/REF(L,60)<1.6 AND H/REF(L,20)<1.5 AND H/REF(L,4)<1.3 AND H/REF(L,10)<1.5 AND COUNT(ZT,5)<=3 AND COUNT(ZT,50)<=5;
ZLC:=O/REF(C,1)>1.07 AND C
BGY:=REF(ZT,1) AND O/REF(C,1)>1.01 AND C
BGYY:=REF(ZT,1) AND H/REF(C,1)>1.07 AND C>O AND LG>100 AND FZG;
EBY:=O/REF(C,1)>1.01 AND C
BGS31:= REF(V=HHV(V,100),1) AND REF(C,1) > REF(C,2) AND V <= 0.7*REF(V,1);
BBZTS31:= REF(ZT,2) AND REF(V,2) >= 2* REF(V,3) AND REF(ZT,1) AND REF(V,1) >= 2* REF(V,2) AND REF(V=HHV(V,60),1) AND V <= 0.7*REF(V,1);
BLZT:= REF(ZT,1) AND REF(V,1) >= REF(V,2)*2 AND REF(V=HHV(V,30),1) AND V<= 0.5*REF(V,1);
ZTBGS31:= REF(ZT,2) AND REF(V=HHV(V,100),1) AND V <= 0.7*REF(V,1);
DRAWICON(ZTBGS31 OR BBZTS31 OR BGS31 OR TZBS31 OR HF OR ZLC OR BGY OR BGYY OR EBY OR BLZT,H*1.015,9),COLORRED;
GLT:=CONST(HHVBARS(V,高量天数));
高量顶:=IF(CURRBARSCOUNT<=GLT+1,CONST(REF(MAX(C,O),GLT)),DRAWNULL);
高量底:=IF(CURRBARSCOUNT<=GLT+1,CONST(IF((REF(MAX(C,O),GLT)-REF(MIN(C,O),GLT))/REF(O,GLT)<=0.033,REF(L,GLT),REF(MIN(C,O),GLT))),DRAWNULL);
STICKLINE(高量底,高量底,高量底,5,0),COLOR009900;
STICKLINE(高量顶,高量顶,高量顶,5,0),COLORRED;
DRAWTEXT(ISLASTBAR,高量顶,STRCAT(' ','安全线')),COLORRED;
DRAWTEXT(ISLASTBAR,高量底,STRCAT(' ','保命线')),COLOR009900;
{---------------------------------------------------------------------------};
{板块属性}
所属板块:=STRCAT('所属板块: ',STRCAT(STRCAT(STRCAT(' 【行业】:',HYBLOCK),STRCAT(' 【地域】:',DYBLOCK)),STRCAT(' 【概念】:',GNBLOCK)));
DRAWTEXT_FIX(O>0,0,0.00,0,所属板块);
自由流通市值:=STRCAT(STRCAT('自由流通市值:', CON2STR(C*FINANCE(46)/100000000,2)),'亿');
DRAWTEXT_FIX(O>0,0,0.1,0,自由流通市值);
DRAWTEXT_FIX(O>0,0,0.05,0,'同花顺:'),COLORFF0000;
DRAWTEXT_FIX(O>0,0.06,0.05,0,EXTERNSTR(0,1)),COLORFF0000;
均价:AMOUNT/VOL/100,NODRAW,COLORBLUE;
涨停:=(C+0.005-REF(C,1))/REF(C,1)*100>=10;
STICKLINE(涨停=1,O,C,3,0),COLORMAGENTA;
向上跳空:=MIN(C,O)>REF(MAX(C,O),1);
明日涨停参考:C*1.1,NODRAW,COLORRED;
STICKLINE(向上跳空=1,O,C,0.4,0),COLORYELLOW;
HS:=VOL/CAPITAL*100;
换手比:HS/REF(HS,1),NODRAW,COLORFF00FF;
虚31:MAX(H,L)-(H-L)/3,NODRAW,COLORFF66CC;
虚21:(L+H)/2,NODRAW,COLORFF66CC;
虚32:MIN(H,L)+(H-L)/3,NODRAW,COLORFF66CC;
三一:MAX(O,C)-ABS(O-C)/3,NODRAW,COLOR000099;
二一:(O+C)/2,NODRAW,COLOR000099;
三二:MIN(O,C)+ABS(O-C)/3,NODRAW,COLOR000099;
AA11:=(REFXV(C,1)+REFXV(C,2)+REFXV(C,3))/3>MAX(O,C) ;
高于实顶:IF(AA11,1,0),COLORFF0099,NODRAW;
一字板:=L=H AND (C+0.005-REF(C,1))/REF(C,1)*100>=10;
STICKLINE(一字板,REF(C,1),C,2.8,-1),COLORFFEEBB;
收阴:=O>C AND (O-C)/O>0.04;
收阳:=O
实体大于4%:=IF(O>C,收阴,收阳);
STICKLINE(实体大于4%,二一,二一,2,0),COLORGRAY;
{跳空}
TK:=C>O AND O>=REF(MAX(C,O),1)+0.01 OR O>=REF(C,1)+0.01 ;
STICKLINE(TK, O,(C-O)*0.01+O,3,0),COLORBLUE;
{STICKLINE(实体大于4%,二一,二一,2,0),COLORGRAY;
高量:=REFX(REF(V,1)>REF(HHV(V,取值),2) AND VMA(VOL,63);
上次高量:=BARSLAST(高量);
最后高量:=CURRBARSCOUNT<=CONST(上次高量)+1;
{高量画线:IF(最后高量,REF(H,上次高量),DRAWNULL),COLORGREEN,DOTLINE;
高量止损:IF(最后高量,REF(L,上次高量),DRAWNULL),COLORGREEN,DOTLINE;};