您现在的位置:程序化交易>> 股票公式>> 同花顺>> 同花顺公式>>正文内容

BOLL综合指标 公式 源码[同花顺公式]

指标代码分析:

 

根据上述分析指标,可以得出以下指标思路及操作建议:
 
1. 涨停和跌停:根据涨停和跌停的情况,可以判断市场的强势和弱势。当出现连续的涨停时,市场处于强势状态,可能是适合买入的时机;而连续的跌停则意味着市场弱势,应谨慎操作。
 
2. 操盘和EMA5:操盘线和5日均线(EMA5)的比较能够反映出市场的平衡状态。当操盘线低于EMA5时,市场偏弱,可以考虑卖出;当操盘线高于EMA5时,市场偏强,可以考虑买入。
 
3. KDJ指标和MACD指标:KDJ指标和MACD指标的交叉和超买超卖信号也是重要的操作参考。当KDJ指标的J线向上穿越0轴或J线和K线交叉并且D线小于26时,为买入信号;当MACD指标的DIFF线和DEA线交叉或MACD柱状图向上穿越0轴时,为买入信号。
 
4. 出货和追单信号:根据出货和追单信号,可以判断市场的卖出压力和买入机会。当出货信号出现在高位并且满足一定条件时,可考虑卖出;而追单信号出现在低位并且满足一定条件时,可考虑买入。
 
5. 上升压力和下跌支撑:上升压力和下跌支撑线可作为短期操作的参考,当价格在上升压力线上方时可以适量减仓或观望,而在下跌支撑线下方时可以适量加仓或考虑买入。
 
综合以上指标思路,建议根据不同市场情况灵活运用各项指标,并结合其他技术分析工具,谨慎决策买卖操作。同时,投资者还应密切关注市场动态和风险控制,以降低投资风险。

 

源码:

M:=17;

P:=2;
N:=5;
大盘指数:INDEXC,NODRAW,colorlimagenta ;
C3:=REF(C,1);//www.cxh99.com
涨停:=IF((C-C3)*100/C3>=(10-0.01*100/C3),1,0);
STICKLINE(涨停,OPEN,CLOSE,2.5,0),coloryellow;
跌停:=IF((C3-C)*100/C3>=(10-0.01*100/C3),1,0);
STICKLINE(跌停,OPEN,CLOSE,2.5,0),colorblue;
EMA5:EMA(C,5),NODRAW;
操盘:=EMA(C,17);
PARTLINE(操盘,操盘<EMA5,colorred,操盘>EMA5,colorgreen),LINETHICK2;
KDJ_K:="KDJ.K"(9,3,3);KDJ_D:="KDJ.D"(9,3,3);KDJ_J:="KDJ.J"(9,3,3);
买1:=CROSS(KDJ_J,0) OR (CROSS(KDJ_J,KDJ_K) AND KDJ_D<26);
买3:=CROSS("MACD.DIF","MACD.DEA") OR CROSS("MACD.MACD",0);
买0:=买1+买3;
{买:=IF(买0>1,买0,0);};
DRAWICON(买0>1,L*0.98,16);
X6:=REF(CLOSE,1);
X7:=((SMA(MAX((CLOSE - X6),0),7,1) / SMA(ABS((CLOSE - X6)),7,1)) * 100);
X8:=CROSS(79,X7);
X9:=FILTER(X8,4);
DRAWTEXT(X9,(HIGH * 1.02),'●出货'),COLOR9000F5;
上升压力: 操盘 + P*STD(CLOSE,M),COLOR0099FF,LINETHICK2;
下跌支撑: 操盘 - P*STD(CLOSE,M),colormagenta,LINETHICK2;
{A1A:=EMA(CLOSE, 9);
A1B:=((A1A - EMA(CLOSE, 5)) < 0);
A1C:=((A1A - EMA(CLOSE, 5)) > 0);
A1D:=BARSLAST(A1B);
A1E:=BARSLAST(A1C);
A1F:=IF((A1E > 0),(CLOSE - REF(CLOSE, 1)) / REF(CLOSE, 1) * 100,0);
A20:=SUM(A1F,0);
A21:=IF((A1D > 0),(0 - 2),0);
A22:=IF((A1E > 0),SUM((CLOSE - REF(CLOSE, 1)) / REF(CLOSE, 1) * 100,A1E),0);
A23:=A22 / A1E;
A25:=EMA(EMA(EMA(CLOSE, 3), 3), 3); }
{DRAWICON(((REF(A21, 1) = (0 - 2)) AND (A21 = 0)),LOW, 5);
DRAWICON(((REF(A1E, 1) > 0) AND (A1E = 0)),HIGH, 6);}
DIF:=EMA(CLOSE,12)-EMA(CLOSE,26);
DEA:=EMA(DIF,9);//www.cxh99.com
MACD1:=(DIF-DEA)*2,COLORSTICK;
A:=MA(CLOSE,5);
B:=MA(CLOSE,20);
TYP:=(HIGH+LOW+CLOSE)/3;
CCI:=(TYP-MA(TYP,84))/(0.015*AVEDEV(TYP,84));
BB:=BETWEEN(REF(CLOSE,1),A,B);
DRAWTEXT(CLOSE>A AND A>B AND B>REF(B,1) AND CROSS(CCI,100) AND MACD1>0 AND REF(MACD1,1)>0,B,'追'),coloryellow;
CBFB:=MA(C,2);
JL:=IF(C>CBFB,V,0);
CL:=IF(C<CBFB,V,0);
JLH:=SUM(JL,4);
CLH:=SUM(CL,4);
LHB:=CLH/JLH;
TJ1:=IF(HHV(LHB,5)>4 AND CROSS(2,LHB) AND C>=O,1,0);
DRAWICON(TJ1,L*0.96,9);
Z:=MA(C,120);
CXH3:=(MA(C,5)-Z)/Z;
CXH4:=MA((CLOSE-LLV(LOW,20))/(HHV(HIGH,20)-LLV(LOW,20))*100,3);
CXH5:=(MA(AMOUNT,5)/MA(VOL,5)/100-MA(AMOUNT,120)/MA(VOL,120)/100)/(MA(AMOUNT,5)/MA(VOL,5)/100);
D1:DRAWTEXT(CLOSE>Z AND REF(CXH4,1)<30 AND CXH4>REF(CXH4,1) AND REF(CXH4,1)<REF(CXH4,2) ,LOW ,'B'),colorred;
D2:DRAWTEXT(REF(CXH5,1)<5 AND CXH5>REF(CXH5,1) AND REF(CXH5,1)<REF(CXH5,2) AND CXH3<-0.3,LOW ,'B'),COLORGREEN;//http://www.cxh99.com
D3:DRAWTEXT(CROSS(CXH4,5) AND CXH3<-0.4,LOW ,'B'),colorblue;
Y:=MA(C,120);
CXH6:=(MA(C,5)-Y)/Y;
CXH7:=MA((CLOSE-LLV(LOW,10))/(HHV(HIGH,10)-LLV(LOW,10))*100,3);
CXH8:=(MA(AMOUNT,5)/MA(VOL,5)/100-MA(AMOUNT,120)/MA(VOL,120)/100)/(MA(AMOUNT,5)/MA(VOL,5)/100);
D4:DRAWTEXT(CLOSE<Y AND Y<REF(Y,1) AND REF(CXH7,1)>80 AND CXH7<REF(CXH7,1) AND REF(CXH7,1)>REF(CXH7,2),HIGH,'S'),coloryellow;
D5:DRAWTEXT(CROSS(90,CXH7) AND CXH8>0.2,HIGH,'S'),COLORGREEN;//http://www.cxh99.com
D6:DRAWTEXT(CROSS(95,CXH7) AND CXH6>0.5,HIGH ,'S'),colorred;
MAA5:=MA(C,5),COLORFF00FF,LINETHICK2;
MAA10:=MA(C,10);//cxh99-com
MAA30:=MA(C,30),colorred;
KS:=IF(MAA10>MAA30,MAA10,MAA30),colorblue;
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;
X1:=(C+L+H)/3;
BB13:=ATAN(EMA(X1,13)-REF(EMA(X1,13),1))*3.1416*10;
EMA8:=EMA(C,8);
DRAWTEXT(FILTER(BB13>1 AND EMA(X1,13)>REF(EMA(X1,8),1),10),
EMA8,'∠45升'),colorwhite;
A01:=MA(CLOSE, 28);
A02:=MA(CLOSE, 66);
A03:=AMOUNT / VOL / 100.000;
A04:=SUMBARS(VOL,CAPITAL * 1.618);
A05:=IF((A04 > 100.000), 1.033,IF(((A04 <= 100.000) AND (A04 > 33.000)), 1.039, 1.05));
运作成本:MA(A03, 10),NODRAW;
中线成本:EMA(A03, 34) * A05,NODRAW;
总体成本:DMA(中线成本,VOL / CAPITAL),NODRAW;
CXH12:=(2*CLOSE+HIGH+LOW)/4;
CXH13:=IF(YEAR>=2099 AND MONTH>2,0,1);
CXH14:=LLV(LOW,5); CXH15:=HHV(HIGH,4);
散户:=EMA((CXH12-CXH14)/(CXH15-CXH14)*100,4)*CXH13;
庄家:=EMA(0.667*REF(散户,1)+0.333*散户,2)*CXH13;
DRAWTEXT(CROSS(散户,庄家) AND 散户<30,L-0.05,'←低吸'),colorlired;
DRAWTEXT(CROSS(庄家,散户) AND 散户>70,H+0.05,'←高抛'),COLORGREEN;//http://www.cxh99.com
 

 

公式导入教程: 【通达信公式源码导入方法教程】 【同花顺公式源码导入方法教程】 【大智慧新一代公式源码导入方法教程

 

 

有思路,想编写各种指标公式,交易模型,选股公式,还原公式的朋友

可联系技术人员 QQ: 262069696  点击在线交流或微信:cxhjy888 进行 有偿收费 编写!(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)

怎么收费,代编流程等详情请点击查阅!

(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)

 


【字体: 】【打印文章】【查看评论

相关文章

    没有相关内容