通达信分时乾坤线分时主图指标 T+0高抛低吸 源码 附图

{分时乾坤线分时主图源码如下}

日:=500;昨前:=60;
高:=REF(HHV(H,日),昨前);
低:=REF(LLV(L,日),昨前);
H1:=高-(高-低)*1;
H2:=高-(高-低)*0.91;
H3:=高-(高-低)*0.85;
H4:=高-(高-低)*0.809;
H5:=高-(高-低)*0.777;
H6:=高-(高-低)*0.707;
H7:=高-(高-低)*0.666;
H8:=高-(高-低)*0.618;
H9:=高-(高-低)*0.563;
H10:=高-(高-低)*0.5;
H11:=高-(高-低)*0.424;
H12:=高-(高-低)*0.382;
H13:=高-(高-低)*0.309;
H14:=高-(高-低)*0.25;
H15:=高-(高-低)*0.191;
H16:=高-(高-低)*0.1375;
H17:=高-(高-低)*0.0807;
一:REFDATE(H2,DATE)POINTDOT,COLORLIRED;
二:=REFDATE(H3,DATE),COLORYELLOW;
三:=REFDATE(H4,DATE),COLORLIBLUE;
四:=REFDATE(H5,DATE),COLORLIRED;
五:=REFDATE(H6,DATE),COLORYELLOW;
六:=REFDATE(H7,DATE),COLORLIBLUE;
七:=REFDATE(H8,DATE),COLORLIRED;
八:=REFDATE(H9,DATE),COLORYELLOW;
九:=REFDATE(H10,DATE),COLORLIBLUE;
十:=REFDATE(H11,DATE),COLORLIRED;
十一:=REFDATE(H12,DATE),COLORYELLOW;
十二:=REFDATE(H13,DATE),COLORLIBLUE;
十三:=REFDATE(H14,DATE),COLORLIRED;
十四:=REFDATE(H15,DATE),COLORYELLOW;
十五:=REFDATE(H16,DATE),COLORLIBLUE;
十六:REFDATE(H17,DATE)POINTDOT,COLOR00FF00;
底:REFDATE(H1,DATE)DOTLINE,COLOR3A3A3A;
顶:REFDATE(高,DATE)DOTLINE,COLOR3A3A3A;
DRAWKLINE(HIGH,OPEN,LOW,CLOSE);
买:=CROSS(C,一);
卖:=CROSS(十六,C);
DRAWICON(买,底,25);
DRAWICON(卖,顶,6);
最新:C,LINETHICK9,COLORFFFF00;
IF(C>=REF(C,1),C,DRAWNULL),LINETHICK9,COLORRED;
AA:=SUM(AMOUNT,BARSCOUNT(C))/SUM(VOL*100,BARSCOUNT(C));
BB:=BETWEEN(C/AA,C+H,C-H);
DRAWICON(ISLASTBAR AND C>REF(C,1),C,1);
DRAWICON(ISLASTBAR AND C<REF(C,1),C,2);
FSHORT:=30;
FLONG:=60;
乾坤线:EMA(CLOSE,FLONG),COLORYELLOW;
操盘线:=EMA(CLOSE,FSHORT);
多线:IFF(操盘线>乾坤线,操盘线 ,DRAWNULL)CIRCLEDOT ,COLORFF00FF,LINETHICK9;
空线:IFF(操盘线<=乾坤线,操盘线,DRAWNULL)CIRCLEDOT ,COLOR00FF00,LINETHICK9;
买信号:=REF(操盘线,1)<=REF(乾坤线,1) AND 操盘线>乾坤线;
卖信号:=REF(操盘线,1)>=REF(乾坤线,1) AND 操盘线<乾坤线;
DRAWICON(买信号,乾坤线,25);
DRAWICON(卖信号,操盘线,6);
实量:=SUM(VOL,FROMOPEN);
虚拟量:=实量/240*FROMOPEN;
SZB:=实量/10000;
XZB:=虚拟量/10000;
大单买:=SUM(IF(CLOSE>=REF(CLOSE,1) AND VOL*C/100/8>=25,VOL,0),FROMOPEN);
大单卖:=SUM(IF(CLOSE<REF(CLOSE,1) AND VOL*C/100/8>=25,VOL,0),FROMOPEN);
ZB1:=大单买/实量*100;
ZB2:=大单卖/实量*100;
DRAWRECTREL(919,CONST(100-ZB1)*1000/100,939,1000,RGB(200,50,0));
DRAWRECTREL(939,CONST(100-ZB2)*1000/100,959,1000,RGB(0,255,0));
DRAWTEXT_FIX(1,0.8,0.32,0,STRCAT(STRCAT('【大单买】',CON2STR(ZB1,2)),'%')),COLOR0032FF;
DRAWTEXT_FIX(1,0.8,0.42,0,STRCAT(STRCAT('【大单卖】',CON2STR(ZB2,2)),'%')),COLORGREEN;
小单买:=SUM(IF(CLOSE>=REF(CLOSE,1) AND VOL*C/100/8<25,VOL,0),FROMOPEN);
小单卖:=SUM(IF(CLOSE<REF(CLOSE,1) AND VOL*C/100/8<25,VOL,0),FROMOPEN);
ZB3:=小单买/实量*100;
ZB4:=小单卖/实量*100;
DRAWRECTREL(959,CONST(100-ZB3)*1000/100,979,1000,90);
DRAWRECTREL(979,CONST(100-ZB4)*1000/100,999,1000,RGB(100,100,100));
DRAWTEXT_FIX(1,0.8,0.52,0,STRCAT(STRCAT('【小单买】',CON2STR(ZB3,2)),'%')),COLORYELLOW;
DRAWTEXT_FIX(1,0.8,0.62,0,STRCAT(STRCAT('【小单卖】',CON2STR(ZB4,2)),'%')),COLORYELLOW;

星期:=WEEKDAY,NODRAW;
日1:=DATETODAY(DATE);
上市日:=REF(DATE,TOTALBARSCOUNT-CURRBARSCOUNT);
自然日:=日1-DATETODAY(上市日)+1;
ZB:=(自然日-REF(自然日,1))!=星期-REF(星期,1)OR TOTALBARSCOUNT-CURRBARSCOUNT=0;
本周第几天:=BARSLAST(ZB)+1;
MA1:=REF(C,本周第几天);
MA2:=REF(MA1,本周第几天);
MA3:=REF(MA2,本周第几天);
MA4:=REF(MA3,本周第几天);
MA5:=REF(MA4,本周第几天);
MA6:=REF(MA5,本周第几天);
MA7:=REF(MA6,本周第几天);
MA8:=REF(MA7,本周第几天);
MA9:=REF(MA8,本周第几天);
十周价:=(C+MA1+MA2+MA3+MA4+MA5+MA6+MA7+MA8+MA9)/10;
决策:REFDATE(十周价,DATE),COLOREE8FFF,LINETHICK2;
DRAWTEXT(ISLASTBAR,决策,' 决策线'),COLORYELLOW;
SUM(AMOUNT,0)/SUM(VOL,0)/100 ,LINETHICK1,COLORYELLOW;
DRAWICON(CROSS(C,决策),C,1);

N0:=STRCAT(CON2STR(YEAR,0),' 年 ');
Y:=STRCAT(CON2STR(MONTH,0),' 月 ');
R:=STRCAT(CON2STR(DAY,0),' 日 ');
SJ:=STRCAT(STRCAT(N0,Y), R);
DRAWTEXT_FIX(C>0,0.2,62,0,SJ);

M1Q:="FSYY.T1#DAY"/100;
MHS:="FSYY.HS#DAY";
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.22,0.85,0,STRCAT('量比: ',CON2STR(DYNAINFO(17),2))),COLORFF9900;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.22,0.55,0,STRCAT('换手率: ',CON2STR(MHS,2))),COLORDDDDDD;
MHST:="FSYY.HST#DAY";
QHST:="FSYY.HST2#DAY";
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.22,0.65,0,STRCAT('昨天: ',CON2STR(MHST,2))),COLORMAGENTA;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.22,0.75,0,STRCAT('前天: ',CON2STR(QHST,2))),COLOR0080FF;
DRAWTEXT_FIX(ISLASTBAR,0.1,0.15,0,GNBLOCK),COLORGREEN;
DRAWTEXT_FIX(ISLASTBAR,0.1,0.25,0,FGBLOCK),COLORGREEN;
DRAWTEXT_FIX(ISLASTBAR,0.1,0.35,0,ZSBLOCK);



DRAWTEXT_FIX(1,0.22,0.5,0,STRCAT('均价:',CON2STR(SUM(V*C,0)/SUM(V,0),2))),COLOR0088FF;

今开:DYNAINFO(4),COLORFF9900,LINETHICK3;
DRAWTEXT(CURRBARSCOUNT=8,今开,' 开盘线'),COLOR8500DE,LINETHICK2;
DRAWGBK(1,RGB(0,0,0),RGB(0,0,0),0,'019',0);


DRAWTEXT_FIX(ISLASTBAR,0.5,0.07,0,CODE),COLORWHITE;
DRAWTEXT_FIX(ISLASTBAR,0.65,0.07,0,STKNAME)COLORWHITE;

DRAWTEXT_FIX(ISLASTBAR,0.001,0.05,0,GNBLOCK),COLORCYAN;{概念};
DRAWTEXT_FIX(1,0,0.87,0,'【涨因】')COLOR0000FF;
DRAWTEXT_FIX(1,0.05,0.85,0,STRCAT(STRCAT(STRCAT(STRCAT(EXTERNSTR(0,9882),'首封时间_'),EXTERNSTR(0,9883)),'末封时间_'),EXTERNSTR(0,9884)))COLORFF00FF; {最近涨停信息:包括首次涨停,最后涨停和个股对应新闻}
DRAWTEXT_FIX(1,0.05,0.90,0,EXTERNSTR(0,9885))COLORFF00FF;{最近涨停信息:对应板块的信息};



{NK副图源码如下}

{NK}
N:=5;
庄A:(O+C)/2;
庄B:REF(C,1)*1.1;
庄C:REF(C,1)*0.9;
庄D:REF(L,1);
庄E:O;
庄F:(H+L)/2;
庄G:REF(C,2);
庄H:(REF(C,1)/REF(C,2)-1)*100;
庄I:REF(V,1);
庄J:AMOUNT/VOL/100;
庄K:REF(C,1);
庄L:REF(AMO.AMOW,1);
庄M:DYNAINFO(58)*DYNAINFO(37)/100;
庄N:H;
庄O:100*((DYNAINFO(5)-DYNAINFO(3))/DYNAINFO(3));
庄P:(INDEXC-REF(INDEXC,1))/REF(INDEXC,1);
庄Q:100*((DYNAINFO(6)-DYNAINFO(3))/DYNAINFO(3));
庄R:(HY_INDEXC-REF(HY_INDEXC,1))/REF(HY_INDEXC,1);
庄S:WINNER(CLOSE)*100;
庄T:(C/REF(C,4)-1)*100;
庄U:DYNAINFO(15)/DYNAINFO(4)/100;
庄V:1;
庄W:2;
庄X:REF(O,1);
庄Y:REF(H,1);
庄Z:REF((O+C)/2,1);
ZS:(INDEXC-REF(INDEXC,N))/REF(INDEXC,N);
庄ZJ:REF(AMOUNT/VOL/100,1);
MA5:MA(C,5);
MA10:MA(C,10);
MA20:MA(C,20);
MA30:MA(C,30);
MA60:MA(C,60);
MA120:MA(C,120);
MA250:MA(C,239);
ZJL:REF(MA(V,5),1);
CDT:H=ZTPRICE(REF(C,1),0.1) AND H>C;
幅度:(O/REF(C,1)-1)*100;

昨量:REF(V,1);
今量:V;
五日量均:MA(V,5);
十日量均:MA(V,10);
五日额均:MA(AMO,5);
十日额均:MA(AMO,10);
QA:REF(AMO,1)/100000000;
QB:REF(AMO,2)/10000;
QC:REF(AMO,3)/10000;
QD:REF(AMO,4)/10000;
QE:REF(AMO,5)/10000;

ROE:FINANCE(30)/FINANCE(19)*100;
ZYLTP:FINANCE(46)/10000;
攻防价位:(REF((H-L)*0.618+L,1));
GJ:=(C+H+L+O)/4;
明日阻力:=L+(GJ-L)+(C-L);
明日支撑:=L+(C-GJ);
今日阻力:REF(明日阻力, 1);
今日支撑:REF(明日支撑, 1);
总买:CUR_BUYORDER;
总卖:CUR_SELLORDER;
超B:=L2_AMO(0,2)/10000.0,NODRAW;
大B:=L2_AMO(1,2)/10000.0,NODRAW;
超S:=L2_AMO(0,3)/10000.0,NODRAW;
大S:=L2_AMO(1,3)/10000.0,NODRAW;
总成交额:=AMOUNT/10000.0,NODRAW;
大单净流入:=(超B+大B)-(超S+大S);
大单净比:100*大单净流入/总成交额;
量能饱和:100*(AMOUNT/C)/(HHV(AMOUNT,20)/HHV(C,20)),NODRAW;
委比:(CUR_BUYORDER-CUR_SELLORDER)/(CUR_BUYORDER+CUR_SELLORDER)*100;



{FSYY引用副源码如下}

{FSYY}
T1:REF(MA(V,5),1);
HS:V/CAPITAL*100;
HST:REF(V/CAPITAL*100,1);
HST2:REF(V/CAPITAL*100,2);






未来函数检测结果如下:
该公式包含未来函数:WINNER
该公式包含未来函数:CAPITAL
该公式包含未来函数:DYNAINFO
该公式包含未来函数:FINANCE
解密、定制、编写股票指标请联系QQ或微信同号:88652583
相关股票指标公式

联系我们  |  股票指标网  |  指标网   |  指标公式  |   加入收藏   |  设为主页

@2005-2023 粤ICP备2023063687号-2 股票指标网别名指标网仅为互联网文章,所有股票指标公式及文章仅供学习研究,并不构成投资建议,请勿以此为依据进行股票交易,由此引起的投资亏损与本站无关。股票指标网均来源互联网收集整理,如不慎侵犯了你的权益,请联系我们告知,我们将做删除处理
QQ:88652583 微信 88652583
sitemap站点地图