公式指标平台 股票指标公式源码分享 登录 注册
公式指标平台
未来函数检测
首 页 金钻指标 通达信公式 大智慧公式 同花顺公式 文华财经公式 操盘手公式 东财通公式 飞狐公式 其他公式 公式解答 股票软件 股票池
当前位置:→ 公式指标平台 > 通达信公式 > 正文 → 正文

通达信异动停牌监控指标公式源码副图

发布时间:2023/9/21 8:42:11  浏览次数:

{标记最近10日}
DRAWICON(V=CONST(REF(V,9)),1,22);STICKLINE(V=CONST(REF(V,9)),0,0.9,0.5,0),COLORFFFFFF;
DRAWNUMBER(V=CONST(REF(V,8)),1,9);
DRAWNUMBER(V=CONST(REF(V,7)),1,8);
DRAWNUMBER(V=CONST(REF(V,6)),1,7);
DRAWNUMBER(V=CONST(REF(V,5)),1,6);
DRAWNUMBER(V=CONST(REF(V,4)),1,5);
DRAWNUMBER(V=CONST(REF(V,3)),1,4);
DRAWNUMBER(V=CONST(REF(V,2)),1,3);
DRAWNUMBER(V=CONST(REF(V,1)),1,2);
DRAWNUMBER(V=CONST(REF(V,0)),1,1);
{计算10日、30日涨幅停牌}
距10日停牌需涨:=100-(C-REF(C,9))/REF(C,9)*100,NODRAW;
距30日停牌需涨:=200-(C-REF(C,29))/REF(C,29)*100,NODRAW;
DRAWTEXT_FIX(ISLASTBAR AND 距10日停牌需涨>=20,0.00,0.06,0,STRCAT('距10日停牌还需涨幅:',STRCAT(CON2STR(距10日停牌需涨,2),' %'))),COLORWHITE;
DRAWTEXT_FIX(ISLASTBAR AND 距10日停牌需涨<20,0.00,0.06,0,STRCAT('距10日停牌还需涨幅:',STRCAT(CON2STR(距10日停牌需涨,2),' %'))),COLORGREEN;
DRAWTEXT_FIX(ISLASTBAR AND 距30日停牌需涨>=20,0.00,0.26,0,STRCAT('距30日停牌还需涨幅:',STRCAT(CON2STR(距30日停牌需涨,2),' %'))),COLORWHITE;
DRAWTEXT_FIX(ISLASTBAR AND 距30日停牌需涨<20,0.00,0.26,0,STRCAT('距30日停牌还需涨幅:',STRCAT(CON2STR(距30日停牌需涨,2),' %'))),COLORGREEN;
{计算异动}
个股0:=C;
个股1:=REF(C,1);
个股2:=REF(C,2);
个股3:=REF(C,3);
标指0:=IF(CODELIKE('00'),"399107$C",IF(CODELIKE('60'),"999998$C",IF(CODELIKE('30'),"399102$C",IF(CODELIKE('68'),"000688$C",0))));
标指1:=REF(标指0, 1);
标指2:=REF(标指0, 2);
标指3:=REF(标指0, 3);
S1:=IF((((个股0/个股2)-1)*100-((标指0/标指2)-1)*100)>20,2,0),;
S2:=IF((((个股0/个股3)-1)*100-((标指0/标指3)-1)*100)>20,3,0),;
S21:=IF(S1=2 OR S2=3,1,0);
S22:=IF(S1+S2=5,1,IF(S2=3,2,1));
A1:=S21 AND REF(S21,1)=0 AND REF(S21,2)=0;
STICKLINE(A1,0,0.5,3,0),COLORMAGENTA;
A2:=BArslAST(A1),NODRAW;
A21:=S21 AND REF(A1,1)=0 AND REF(A1,S22)=0;
A22:=A21 AND REF(A21,1)=0 AND REF(A21,S22)=0;
STICKLINE(A22,0,0.5,3,0),COLORMAGENTA;
A3:=BARSLAST(A22),NODRAW;
A31:=S21 AND REF(A22,1)=0 AND REF(A22,S22)=0;
A32:=A31 AND REF(A31,1)=0 AND REF(A31,S22)=0;
STICKLINE(A32,0,0.5,3,0),COLORMAGENTA;
A4:=BARSLAST(A32),NODRAW;
A41:=S21 AND REF(A32,1)=0 AND REF(A32,S22)=0;
A42:=A41 AND REF(A41,1)=0 AND REF(A41,S22)=0;
STICKLINE(A42,0,0.5,3,0),COLORMAGENTA;
A5:=BARSLAST(A42),NODRAW;
A51:=S21 AND REF(A42,1)=0 AND REF(A42,S22)=0;
A52:=A51 AND REF(A51,1)=0 AND REF(A51,S22)=0;
STICKLINE(A52,0,0.5,3,0),COLORMAGENTA;
{今日涨幅界限}
今一日涨幅界限:=(((20+((标指0/标指1)-1)*100)/100+1)*个股1/个股1-1)*100,COLORMAGENTA,NODRAW;
今两日涨幅界限:=(((20+((标指0/标指2)-1)*100)/100+1)*个股2/个股1-1)*100,COLORMAGENTA,NODRAW;
今三日涨幅界限:=(((20+((标指0/标指3)-1)*100)/100+1)*个股3/个股1-1)*100,COLORMAGENTA,NODRAW;
{
今一日涨幅界限:20-((个股0/个股1)-1)*100-((标指0/标指1)-1)*100+((个股0/个股1)-1)*100+((标指0/标指1)-1)*100,COLORMAGENTA,NODRAW;
今两日涨幅界限:20-((个股0/个股2)-1)*100-((标指0/标指2)-1)*100+((个股1/个股2)-1)*100+((标指1/标指2)-1)*100,COLORMAGENTA,NODRAW;
今三日涨幅界限:20-((个股0/个股3)-1)*100-((标指0/标指3)-1)*100+((个股1/个股3)-1)*100+((标指1/标指3)-1)*100,COLORMAGENTA,NODRAW;
}
B:=IF(今两日涨幅界限-今三日涨幅界限>0,今三日涨幅界限,今两日涨幅界限);
B1:=IF(A2=1 OR A3=1 OR A4=1 OR BARSLAST(A42)=1,今一日涨幅界限,0),NODRAW;
B2:=IF(A2=2 OR A3=2 OR A4=2 OR BARSLAST(A42)=2,今两日涨幅界限,0),NODRAW;
今异动涨幅界限:IF(B1,B1,IF(B2,B2,B)),NODRAW;
DRAWTEXT_FIX(ISLASTBAR AND 今异动涨幅界限>10,0.20,0.06,0,STRCAT('今涨幅异动界限:',STRCAT(CON2STR(今异动涨幅界限,2),' %')))COLORWHITE;
DRAWTEXT_FIX(ISLASTBAR AND 今异动涨幅界限<=10,0.20,0.06,0,STRCAT('今涨幅异动界限:',STRCAT(CON2STR(今异动涨幅界限,2),' %')))COLORGREEN;
{明日涨停是否会触发异动}
明一日涨幅异动:=((ZTPRICE(C,0.1)/REF(C,0))-1)*100-((标指0/标指0)-1)*100,NODRAW;
明两日涨幅异动:=((ZTPRICE(C,0.1)/REF(C,1))-1)*100-((标指0/标指1)-1)*100,NODRAW;
明三日涨幅异动:=((ZTPRICE(C,0.1)/REF(C,2))-1)*100-((标指0/标指2)-1)*100,NODRAW;
B3:=IF(明两日涨幅异动-明三日涨幅异动>0,明两日涨幅异动,明三日涨幅异动),NODRAW;
B4:=IF(A1 OR A22 OR A32 OR A42,1,0),NODRAW;
B5:=IF(A2=1 OR A3=1 OR A4=1 OR BARSLAST(A42)=1,今两日涨幅界限,0),NODRAW;
B6:=IF(B4,B4,IF(B5,B5,B3)),NODRAW;
明涨停是否异动:=IF(B6>19.9,1,0);
DRAWTEXT_FIX(ISLASTBAR AND 明涨停是否异动=0,0.20,0.26,0,STRCAT('明涨停是否异动:','否')),COLORWHITE;
DRAWTEXT_FIX(ISLASTBAR AND 明涨停是否异动=1,0.20,0.26,0,STRCAT('明涨停是否异动:','是')),COLORGREEN;
{今日涨幅}
今涨幅:=(C/REF(C,1)-1)*100;
DRAWTEXT_FIX(ISLASTBAR AND 今涨幅>0,0.40,0.26,0,STRCAT('今涨幅::',STRCAT(CON2STR(今涨幅,2),' %'))),COLORFF00FF;
DRAWTEXT_FIX(ISLASTBAR AND 今涨幅<=0,0.40,0.26,0,STRCAT('今涨幅::',STRCAT(CON2STR(今涨幅,2),' %'))),COLOR00FF00;
{十日内异动次数}
十日内异动次数:=COUNT(A1 OR A22 OR A32 OR A42,10);
DRAWTEXT_FIX(ISLASTBAR AND 十日内异动次数=0,0.40,0.06,0,STRCAT('十日内异动次数:',STRCAT(CON2STR(十日内异动次数,0),' 次')))COLORWHITE;
DRAWTEXT_FIX(ISLASTBAR AND 十日内异动次数>0,0.40,0.06,0,STRCAT('十日内异动次数:',STRCAT(CON2STR(十日内异动次数,0),' 次')))COLORGREEN;

通达信异动停牌监控指标公式源码副图

通达信异动停牌监控指标公式源码副图

资源下载链接   资源大小:unknow

手机移动版 - 关于我们 - 联系我们 - 广告合作 - 下载声明 - 网站帮助 - 友情链接 - 网站地图 - TOP
湘ICP备09016573号 增值电信业务经营ICP许可证:湘B2-20210269 湘公网安备43108102000039号
Copyright © GSZB.COM ,All Rights Reserved.
股票公式,股票指标,股票软件,股票知识