涨停精选主图 源码分享 标注涨停
M1:=5;
M2:=10;
M3:=20;
M4:=60;
M5:=120;
M6:=250;
MA1:MA(CLOSE,M1);
MA2:MA(CLOSE,M2);
MA3:MA(CLOSE,M3);
MA4:MA(CLOSE,M4);
MA5:MA(CLOSE,M5);
MA6:MA(CLOSE,M6);
地域板块:=STRCAT(STRCAT(HYBLOCK,'-'),STRCAT('-',DYBLOCK));
概念板块:=STRCAT('--',GNBLOCK);
{总股本:=STRCAT(STRCAT(' 总股本:',CON2STR(TOTALCAPITAL/1000000,2)),'亿');
流通盘:=STRCAT(STRCAT(' 流通盘:',CON2STR(CAPITAL/1000000,2)),'亿');
全流通:=STRCAT(STRCAT(' 流通比:',CON2STR(CAPITAL/TOTALCAPITAL*100,2)),'%');}
流通市值:=STRCAT(STRCAT('流通市值:',CON2STR((CAPITAL/1000000)*C,2)),'亿');
{上市日期:=STRCAT('上市日期: ',CON2STR(HHV((BARSCOUNT(C)=0)*(DATE+19000000),0),0));}
{股本市值:=STRCAT('【股本市值】',STRCAT(STRCAT(STRCAT(STRCAT(总股本,流通盘),全流通),市值),上市日期));}
{股本市值:=STRCAT('.',STRCAT(流通市值,上市日期));}
股本市值:=STRCAT(流通市值,'元');
{市盈率:=STRCAT(' 市盈率:',CON2STR(C/FINANCE(33),2));
市销率:=STRCAT(' 市销率:',CON2STR(C/(FINANCE(20)/FINANCE(1)),2));
市净率:=STRCAT(' 市净率:',CON2STR(C/FINANCE(34),2));
净资收益率:=STRCAT(' 净资收益率:',CON2STR(FINANCE(33)/FINANCE(34)*100,2));
毛利率:=STRCAT(' 毛利率:',CON2STR((FINANCE(20)-FINANCE(21))/FINANCE(20)*100,2));
净利润率:=STRCAT(' 净利率:',CON2STR(FINANCE(30)/FINANCE(20)*100,2));
主营利润率:=STRCAT(' 主营利润率:',CON2STR(FINANCE(23)/FINANCE(20)*100,2));
当前业绩:=STRCAT('【当前业绩】',STRCAT(STRCAT(STRCAT(STRCAT(STRCAT(STRCAT(市盈率,市销率),市净率),净资收益率),毛利率),净利润率),主营利润率));}
DRAWTEXT_FIX(ISLASTBAR,0.005,0.02,0,地域板块),COLORCYAN;
DRAWTEXT_FIX(ISLASTBAR,0.25,0.02,0,概念板块),COLORYELLOW;
DRAWTEXT_FIX(ISLASTBAR,0.005,0.28,0,股本市值),COLORCYAN;
{DRAWTEXT_FIX(ISLASTBAR,0.005,0.12,0,当前业绩),COLORMAGENTA;}
{DRAWTEXT_FIX(1,0.005,0.17,0,'莸利比例:'),COLORYELLOW;}
{DRAWNUMBER_FIX(1,0.06,0.17,0,CONST(WINNER(C )*100)),COLORYELLOW;}
{X1:=(FINANCE(11)-FINANCE(15))/FINANCE(10)*1.2;
X2:=(FINANCE(31)+FINANCE(17))/FINANCE(10)*1.4;{盈余公积用资本公积金代替};
{X3:=FINANCE(23)/FINANCE(10)*3.3;
X4:=FINANCE(19)/FINANCE(15)*0.6;{缺长期负债或负债总额}
{X5:=FINANCE(20)/FINANCE(15)*0.999;}
{Z值:=X1+X2+X3+X4+X5;
预警:=IF(Z值<1.2,'重警',IF(Z值>=1.2 AND Z值<2.6,'轻警','无警'));
财务预警:=STRCAT('财务预警: ',STRCAT(预警,STRCAT('-Z值: ',CON2STR(Z值,3))));
优质资产率:=STRCAT(' 优质资产率: ',CON2STR((FINANCE(19)-FINANCE(22)-FINANCE(27))/FINANCE(19),2));{理论上越大越好但不同行业有不同标准};
{现金负债比:=STRCAT(' 现金负债比: ',CON2STR(FINANCE(25)/FINANCE(15),3));{缺长期负债或负债总额,理论上越大越好但不同行业有不同标准};
{财务系数:=STRCAT('风险系数: ',STRCAT(STRCAT(财务预警,优质资产率),现金负债比));
DRAWTEXT_FIX(ISLASTBAR,0.005,0.23,0,财务系数),COLORGREEN;}
{涨跌停 K线变色,通达信公式}
NE:=IF(NAMELIKE('S') OR NAMELIKE('*S'),0.05,0.1);{通用个股/ST股}
涨停:=C/REF(C,1)-1>=NE-0.01/REF(C,1) AND C=H AND PERIOD=5;{仅在日线上变色}
STICKLINE(涨停,C,O,-1,0),COLORFF00F5;
跌停:=REF(C,1)/C-1>=NE-0.01/REF(C,1) AND L=C AND PERIOD=5;
STICKLINE(跌停,C,O,-1,0),COLOR00FF00;
{曾涨跌停 K线变色}
曾涨停:=H/REF(C,1)-1>=NE-0.01/REF(C,1) AND C<H AND PERIOD=5;
STICKLINE(曾涨停,H-(H-MAX(O,C)),H,0,0),COLORFF00B5;
曾跌停:=REF(C,1)/L-1>=NE-0.01/REF(C,1) AND L<C AND PERIOD=5;
STICKLINE(曾跌停,L+(MIN(O,C)-L),L,0,0),COLOR00BB00;
{涨跌停开盘 K线变色}
涨停开盘:=O/REF(C,1)-1>=NE-0.01/REF(C,1) AND O=H AND PERIOD=5;{阴阳线的十分之一变色}
STICKLINE(涨停开盘,C+(O-C)*0.9,O,-1,0),COLORFF00F5;
跌停开盘:=REF(C,1)/O-1>=NE-0.01/REF(C,1) AND L=O AND PERIOD=5;
STICKLINE(跌停开盘,C-(C-O)*0.9,O,-1,0),COLOR00FF00;
{竞价情况}
JJCJL:=DYNAINFO(15)/DYNAINFO(4)/100;
JJJEDW:=IF(DYNAINFO(15)>10000,'万元','元');
JJJE:=IF(DYNAINFO(15)>10000,CON2STR(DYNAINFO(15)/10000,1),CON2STR(DYNAINFO(15),1));
JJJE1:=STRCAT(JJJE,JJJEDW);
JJ:=STRCAT('竞价量额:',STRCAT(CON2STR(JJCJL/10000,2),'万手'));
JJ1:=STRCAT(JJ,' = ');{ 公式源码 }
DRAWTEXT_FIX(1,0.25,0.15,0,STRCAT(JJ1,JJJE1))COLORCYAN;{竞价量额位置}
{DRAWTEXT_FIX(1,0.95,0.50,0,STRCAT('占昨成交:',STRCAT(CON2STR(DYNAINFO(15)/分时引用.昨日额#DAY*100,2),'%')))COLORYELLOW;}
今日竞价股数:=DYNAINFO(15)/DYNAINFO(4);
DRAWTEXT_FIX(1,0,0,0,EXTERNSTR(0,1))COLOR00FF00;
ZT:=C>REF(C,1)*1.090 AND C<REF(C,1)*1.105;
DT:=C<REF(C,1)*0.901 AND C>REF(C,1)*0.898;
STICKLINE(ZT,C,O,4,0),COLORRED;
STICKLINE(DT,C,O,4,0),COLORBLUE;
DRAWTEXT(ZT,L-0.1,'涨停'),COLOREE8FFF;
DRAWTEXT(DT,H+0.3,'跌停'),COLORFF9900;
DRAWTEXT_FIX(1,0,2,0,EXTERNSTR(0,1))COLOR00FF00;
未来函数检测结果如下:
该公式包含未来函数:WINNER
该公式包含未来函数:CAPITAL
该公式包含未来函数:DYNAINFO
该公式包含未来函数:FINANCE
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式
原理解析:
M1赋值:5
M2赋值:10
M3赋值:20
M4赋值:60
M5赋值:120
M6赋值:250
输出MA1:收盘价的M1日简单移动平均
输出MA2:收盘价的M2日简单移动平均
输出MA3:收盘价的M3日简单移动平均
输出MA4:收盘价的M4日简单移动平均
输出MA5:收盘价的M5日简单移动平均
输出MA6:收盘价的M6日简单移动平均
地域板块赋值:STRCAT(STRCAT(HYBLOCK,'-'),STRCAT('-',DYBLOCK))
概念板块赋值:STRCAT('--',GNBLOCK)
{总股本:=STRCAT(STRCAT(' 总股本:',CON2STR(TOTAL当前流通股本/1000000,2)),'亿')
流通盘:=STRCAT(STRCAT(' 流通盘:',CON2STR(当前流通股本/1000000,2)),'亿')
全流通:=STRCAT(STRCAT(' 流通比:',CON2STR(当前流通股本/TOTAL当前流通股本*100,2)),'%')
}流通市值:=STRCAT(STRCAT('流通市值:',CON2STR((当前流通股本/1000000)*C,2)),'亿')
{上市日期:=STRCAT('上市日期: ',CON2STR(HHV((C的有效数据周期数=0)*(DATE+19000000),0),0))
}{股本市值赋值:STRCAT('【股本市值】',STRCAT(STRCAT(STRCAT(STRCAT(总股本,流通盘),全流通),市值),上市日期))
}{股本市值赋值:STRCAT('.',STRCAT(流通市值,上市日期))
}股本市值赋值:STRCAT(流通市值,'元')
{市盈率:=STRCAT(' 市盈率:',CON2STR(C/FINANCE(33),2))
市销率:=STRCAT(' 市销率:',CON2STR(C/(FINANCE(20)/FINANCE(1)),2))
市净率:=STRCAT(' 市净率:',CON2STR(C/FINANCE(34),2))
净资收益率:=STRCAT(' 净资收益率:',CON2STR(FINANCE(33)/FINANCE(34)*100,2))
毛利率:=STRCAT(' 毛利率:',CON2STR((FINANCE(20)-FINANCE(21))/FINANCE(20)*100,2))
净利润率:=STRCAT(' 净利率:',CON2STR(FINANCE(30)/FINANCE(20)*100,2))
主营利润率:=STRCAT(' 主营利润率:',CON2STR(FINANCE(23)/FINANCE(20)*100,2))
当前业绩赋值:STRCAT('【当前业绩】',STRCAT(STRCAT(STRCAT(STRCAT(STRCAT(STRCAT(市盈率,市销率),市净率),净资收益率),毛利率),净利润率),主营利润率))
当满足条件ISLASTBAR时,在横轴0.005纵轴0.02位置书写文字
当满足条件ISLASTBAR时,在横轴0.25纵轴0.02位置书写文字
当满足条件ISLASTBAR时,在横轴0.005纵轴0.28位置书写文字
当满足条件ISLASTBAR时,在横轴0.005纵轴0.12位置书写文字
当满足条件1时,在横轴0.005纵轴0.17位置书写文字
}{DRAWNUMBER_FIX(1,0.06,0.17,0,CONST(C 计算的获利盘比例*100)),画黄色
}{X1赋值:(FINANCE(11)-FINANCE(15))/FINANCE(10)*1.2
X2赋值:(FINANCE(31)+FINANCE(17))/FINANCE(10)*1.4
{盈余公积用资本公积金代替}
{X3赋值:FINANCE(23)/FINANCE(10)*3.3
X4赋值:FINANCE(19)/FINANCE(15)*0.6
{缺长期负债或负债总额}{X5赋值:FINANCE(20)/FINANCE(15)*0.999
}{Z值赋值:X1+X2+X3+X4+X5
预警赋值:IF(Z值<1.2,'重警',IF(Z值>=1.2 AND Z值<2.6,'轻警','无警'))
财务预警赋值:STRCAT('财务输出预警: ',STRCAT(预警,STRCAT('-Z值: ',CON2STR(Z值,3))))
优质资产率:=STRCAT(' 优质资产率: ',CON2STR((FINANCE(19)-FINANCE(22)-FINANCE(27))/FINANCE(19),2))
{理论上越大越好但不同行业有不同标准}
{现金负债比:=STRCAT(' 现金负债比: ',CON2STR(FINANCE(25)/FINANCE(15),3))
{缺长期负债或负债总额,理论上越大越好但不同行业有不同标准}
{财务系数:=STRCAT('风险系数: ',STRCAT(STRCAT(财务预警,优质资产率),现金负债比))
当满足条件ISLASTBAR时,在横轴0.005纵轴0.23位置书写文字
}{涨跌停 K线变色,通达信公式}NE赋值:IF(NAMELIKE('S') OR NAMELIKE('*S'),0.05,0.1)
{通用个股/ST股}涨停赋值:C/1日前的C-1>=NE-0.01/1日前的C AND C=H AND PERIOD=5
当满足条件涨停时,在C和O之间画柱状线
跌停赋值:1日前的C/C-1>=NE-0.01/1日前的C AND L=C AND PERIOD=5
当满足条件跌停时,在C和O之间画柱状线
{曾涨跌停 K线变色}曾涨停:=H/1日前的C-1>=NE-0.01/1日前的C AND CSTICKLINE(曾涨停,H-(H-O和C较大值),H,0,0),COLORFF00B5
曾跌停赋值:1日前的C/L-1>=NE-0.01/1日前的C AND LSTICKLINE(曾跌停,L+(O和C的较小值-L),L,0,0),COLOR00BB00
{涨跌停开盘 K线变色}涨停开盘:=O/1日前的C-1>=NE-0.01/1日前的C AND O=H AND PERIOD=5
{阴阳线的十分之一变色}STICKLINE(涨停开盘,C+(O-C)*0.9,O,-1,0),COLORFF00F5
跌停开盘:=1日前的C/O-1>=NE-0.01/1日前的C AND L=O AND PERIOD=5
STICKLINE(跌停开盘,C-(C-O)*0.9,O,-1,0),COLOR00FF00
{竞价情况}JJCJL赋值:开盘金额/开盘价/100
JJJEDW赋值:IF(开盘金额>10000,'万元','元')
JJJE赋值:IF(开盘金额>10000,CON2STR(开盘金额/10000,1),CON2STR(开盘金额,1))
JJJE1:=STRCAT(JJJE,JJJEDW)
JJ赋值:STRCAT('竞价量额:',STRCAT(CON2STR(JJCJL/10000,2),'万手'))
JJ1:=STRCAT(JJ,' = ')
{ 公式源码 }DRAWTEXT_FIX(1,0.25,0.15,0,STRCAT(JJ1,JJJE1))画青色
{竞价量额位置}{DRAWTEXT_FIX(1,0.95,0.50,0,STRCAT('占昨成交:',STRCAT(CON2STR(开盘金额/分时引用.昨日额#DAY*100,2),'%')))画黄色
}今日竞价股数赋值:开盘金额/开盘价
DRAWTEXT_FIX(1,0,0,0,EXTERNSTR(0,1))COLOR00FF00
ZT赋值:C>1日前的C*1.090 AND C<1日前的C*1.105
DT赋值:C<1日前的C*0.901 AND C>1日前的C*0.898
当满足条件ZT时,在C和O之间画柱状线
当满足条件DT时,在C和O之间画柱状线
当满足条件ZT时,在L-0.1和'涨停'位置书写文字
当满足条件DT时,在H+0.3和'跌停'位置书写文字
DRAWTEXT_FIX(1,0,2,0,EXTERNSTR(0,1))COLOR00FF00