当前位置:→ 公式网 > 通达信公式 > 正文 ℃ 公式解密、改选股等业务 联系点击查看详情...
以下是通达信涨跌幅区间买卖法则主图源码(无源码的请下载附件导入)
通达信涨跌幅区间买卖法则主图源码
股价的涨跌的幅度,一般在某一区间会发生变化的。此指标是用彩条做某一涨跌幅度区间发生变化的提示!!
使用时,用调整时间日期找出高点,参数【ZD是调整最近低点的。J=1 J=2是显示涨幅度线,分别是3% 5% 8% 13% 18% 25%】
顶部有显示股价高点到近低点跌幅得幅度,近低点到当前涨幅的幅度。{公式在线提供:www.gszx.com.cn}
C/C++ Code复制内容到剪贴板
- {RQ1(1990,3000,2010),RQ2(1,12,1),RQ3(1,31,1),ZD(0,55,0),RQ3(0,3,0);}
- RQG:=(RQ1-1900)*10000+RQ2*100+RQ3;
- AH:REF(H,BARSLAST(DATE<=RQG )),NODRAW;
- 高价:IF(DATE>=RQG,AH,DRAWNULL),COLORFFFF00;
- 跌幅8%:IF(DATE>=RQG,AH*0.92,DRAWNULL),COLOR6094FF,LINETHICK3;
- 跌幅18%:IF(DATE>=RQG,AH*0.82,DRAWNULL),COLOR6094FF,LINETHICK5;
- 高价A:=IF(DATE>=RQG,AH*0.95,DRAWNULL);
- 高价B:=IF(DATE>=RQG,AH*0.934,DRAWNULL);
- 高价C:=IF(DATE>=RQG,AH*0.90,DRAWNULL);
- 高价D:=IF(DATE>=RQG,AH*0.87,DRAWNULL);
- 高价E:=IF(DATE>=RQG,AH*0.79,DRAWNULL);
- 高价F:=IF(DATE>=RQG,AH*0.75,DRAWNULL);
- DRAWBAND(高价A,RGB(21,138,255),高价B,RGB(21,138,255));
- DRAWBAND(高价C,RGB(21,138,5),高价D,RGB(21,138,5));
- DRAWBAND(高价E,RGB(72,78,255),高价F,RGB(72,78,255));
- 最低:=TROUGHBARS(L,ZD,1);
- 低价:=REF(L,BARSLAST(最低=0));
- 低价_:DRAWLINE(最低=0 AND ZD>0,L,ISLASTBAR,低价,0),COLORFFFF00;
- FU:=C-低价_;
- 低到当前幅度:FU/低价_*100,NODRAW,COLOR00FFFF;
- FUGA:=高价-低价;
- 高到低价幅度%:FUGA/高价*100,NODRAW,COLOR00FFFF;
- STICKLINE(C>=O,LOW,HIGH,0,0),COLOR0000FF;
- STICKLINE(C>=O,CLOSE,OPEN,3,0),COLOR1020EE;
- STICKLINE(C<=O,LOW,HIGH,0,0),COLORFF8800;
- STICKLINE(C<=O,CLOSE,OPEN,3,0),COLORFFCC00;
- _3%:DRAWLINE(最低=0 AND J>=1,L*1.03,ISLASTBAR,低价*1.03,0),COLOR999999;
- _5%:DRAWLINE(最低=0 AND J>=1,L*1.05,ISLASTBAR,低价*1.05,0),COLOR999999;
- _8%:DRAWLINE(最低=0 AND J>=1,L*1.08,ISLASTBAR,低价*1.08,0),COLOR999999;
- _13%:DRAWLINE(最低=0 AND J>=1,L*1.13,ISLASTBAR,低价*1.13,0),COLOR999999;
- _18%:DRAWLINE(最低=0 AND J>=2,L*1.18,ISLASTBAR,低价*1.18,0),COLOR999999;
- _25%:DRAWLINE(最低=0 AND J>=2,L*1.25,ISLASTBAR,低价*1.25,0),COLOR999999;
- DRAWNUMBER(最低=0 AND _3%,_3%,L*1.03),COLORFFFF00;
- DRAWTEXT(最低=0 AND _3%,_3%*1.009,'3%'),COLOR208FFF;
- DRAWNUMBER(最低=0 AND _5%,_5%,L*1.05),COLORFFFF00;
- DRAWTEXT(最低=0 AND _5%,_5%*1.009,'5%'),COLOR208FFF;
- DRAWNUMBER(最低=0 AND _8%,_8%,L*1.08),COLOR999999;
- DRAWTEXT(最低=0 AND _8%,_8%*1.009,'8%'),COLOR208FFF;
- DRAWNUMBER(最低=0 AND _13%,_13%,L*1.13),COLORFFFF00;
- DRAWTEXT(最低=0 AND _13%,_13%*1.009,'13%'),COLOR208FFF;
- DRAWNUMBER(最低=0 AND _18%,_18%,L*1.18),COLORFFFF00;
- DRAWTEXT(最低=0 AND _18%,_18%*1.009,'18%'),COLOR208FFF;
- DRAWNUMBER(最低=0 AND _25%,_25%,L*1.25),COLORFFFF00;
- DRAWTEXT(最低=0 AND _25%,_25%*1.009,'25%'),COLOR208FFF;
- DRAWNUMBER(ISLASTBAR AND 高价,AH*1.009,AH),COLORBBBBBB;
- LC := REF(CLOSE,1);
- RSI1:=SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100;
- GB:IF(RSI1>76,H*1.001,DRAWNULL),CIRCLEDOT,LINETHICK3,COLORFFFF00;
- GBB:IF(RSI1>80,H*1.002,DRAWNULL),CROSSDOT,LINETHICK3,COLOR0000FF;
- AS:=(O+H+L+C)/4;
- BL:EMA(AS,17),LINETHICK2,COLORFF6000;
- DRAWNUMBER(ISLASTBAR AND BL,BL*1.005,BL);
- XGM:=CROSS(C,BL);
- DRAWICON(XGM,BL,9);
- IF(BL>REF(BL,1),BL,DRAWNULL),LINETHICK2,COLORYELLOW;
- IF(BL<REF(BL,1),BL,DRAWNULL),LINETHICK2,COLOR00FF00;
- {请设置计算参数:
- 年度: PARAM#0 显示年度
- 月份: PARAM#1 显示月份
- 日期: PARAM#2 显示日期
- ZD : PARAM#3 找近期低点
- J : PARAM#4 显示涨幅幅度线}
上一篇:通达信一根线主图乖离率附主副图源码 下一篇:通达信主力进场诱多退场洗进洗盘副图源码