您现在的位置:程序化交易>> 股票公式>> 通达信>> 通达信公式>>正文内容

分时简化(通达信公式 主图指标公式 公式、源码 测试图)[通达信公式]

相关标签:

 

{公式名称: 分时简化 公式描述: 含大盘分时}cxh1:=IF(FINANCE(3)!=0,DYNAINFO(3)*(1+0.02),DRAWNULL);cxh2:=IF(FINANCE(3)!=0,DYNAINFO(3)*1.04,DRAWNULL);cxh3:=IF(FINANCE(3)!=0,DYNAINFO(3)*(1-0.015),DRAWNULL);cxh4:=IF(FINANCE(3)!=0,DYNAINFO(3)*(1-0.01),DRAWNULL);DRAWBAND(cxh2,RGB(48,48,48),cxh1,RGB(48,48,48));DRAWBAND(DYNAINFO(3),RGB(68,68,68),cxh3,RGB(68,68,68));DRAWBAND(DYNAINFO(3),RGB(48,48,48),cxh4,RGB(48,48,48));cxh5:=IF(HOUR<12,(HOUR-9.5)*60+MINUTE,(HOUR-11)*60+MINUTE);均线:IF(1,SUM(CLOSE*VOL,cxh5)/SUM(VOL,cxh5),DRAWNULL),COLORYELLOW;DRAWBAND(CLOSE,RGB(58,0,0),均线,RGB(0,58,0));IF(1,SUM(CLOSE*VOL,cxh5)/SUM(VOL,cxh5),DRAWNULL),COLORYELLOW;CLOSE,COLORWHITE;IF(DYNAINFO(5)>DYNAINFO(3)*(1+0.05),DYNAINFO(3)*(1+0.05),DRAWNULL),COLORCCCCCC;IF(DYNAINFO(5)>DYNAINFO(3)*(1+0.07),DYNAINFO(3)*(1+0.07),DRAWNULL),COLORCC00CC;cxh6:=STRCAT(STRCAT(HYBLOCK,DYBLOCK),GNBLOCK);DRAWTEXT_FIX(ISLASTBAR,0.05,0.95,0,cxh6),COLOR00CCCC;cxh7:=STRCAT(STRCAT(120,CON2STR(CAPITAL/1000000,2)),121);cxh8:=STRCAT(STRCAT(122,CON2STR(CAPITAL/1000000*CLOSE,2)),121);cxh9:=STRCAT(cxh7,cxh8);DRAWTEXT_FIX(ISLASTBAR,0.045,0.85,0,cxh9),COLOR00CCCC;cxh10:=IF(1,HHV(HIGH,480),DRAWNULL);cxh11:=IF(1,LLV(LOW,480),DRAWNULL);IF(CLOSE>=REF(cxh10,1),CLOSE,DRAWNULL),COLORRED;IF(CLOSE<=REF(cxh11,1),CLOSE,DRAWNULL),COLORGREEN;cxh12:=(CLOSE+LOW+HIGH)/3;cxh13:=IF(cxh12>REF(cxh12,1),(CLOSE+LOW+HIGH)/3,REF((CLOSE+LOW+HIGH)/3,1));cxh14:=IF(cxh12<REF(cxh12,1),(CLOSE+LOW+HIGH)/3,REF((CLOSE+LOW+HIGH)/3,1));cxh15:=cxh13;cxh16:=(cxh13+cxh14)/2;cxh17:=cxh14;cxh18:=IF(ISLASTBAR,REF(cxh15,1),DRAWNULL);cxh19:=IF(ISLASTBAR,REF(cxh16,1),DRAWNULL);cxh20:=IF(ISLASTBAR,REF(cxh17,1),DRAWNULL);cxh21:=1;STICKLINE(cxh21=1,cxh18,cxh18,20,(-1)),COLOR0000CC;STICKLINE(cxh21=1,cxh19,cxh19,20,(-1)),COLORWHITE;STICKLINE(cxh21=1,cxh20,cxh20,20,(-1)),COLORCCCC00;cxh22:=1;cxh23:=BARSLAST(HOUR=9 AND MINUTE=30+cxh22)+1;cxh24:=IF(FINANCE(3)=0,SUM(AMOUNT,0)/SUM(VOL,0),SUM(AMOUNT,0)/SUM(VOL,0)/100);cxh25:=IF(打工皇帝#DAY,0.025,IF(打工皇帝#DAY,0.04,0.015));cxh26:=IF(打工皇帝#DAY,0.025,IF(打工皇帝#DAY,0.015,0.04));cxh27:=IF(FINANCE(3)=0,cxh25/5,cxh25);cxh28:=IF(FINANCE(3)=0,cxh26/5,cxh26);cxh29:=CLOSE>REF(CLOSE,1) AND CLOSE/cxh24>1+cxh27;cxh30:=CLOSE<REF(CLOSE,1) AND CLOSE/cxh24<1-cxh28;cxh31:=CROSS(SUM(cxh29,0),0.5);cxh32:=CROSS(SUM(cxh30,0),0.5);cxh33:=SUM(cxh31,0)*CROSS(COUNT(CLOSE<REF(CLOSE,1),BARSLAST(cxh31)),0.5);cxh34:=SUM(cxh32,0)*CROSS(COUNT(CLOSE>REF(CLOSE,1),BARSLAST(cxh32)),0.5);cxh35:=CONST(SUM(IF(cxh33,REF(CLOSE,1),DRAWNULL),0));cxh36:=CONST(SUM(IF(cxh34,REF(CLOSE,1),DRAWNULL),0));cxh37:=CROSS(SUM(cxh29 AND CLOSE>cxh35*(1+cxh27),0),0.5);cxh38:=CROSS(SUM(cxh30 AND CLOSE<cxh36*(1-cxh28),0),0.5);cxh39:=SUM(cxh37,0)*CROSS(COUNT(CLOSE<REF(CLOSE,1),BARSLAST(cxh37)),0.5);cxh40:=SUM(cxh38,0)*CROSS(COUNT(CLOSE>REF(CLOSE,1),BARSLAST(cxh38)),0.5);cxh41:=CONST(SUM(IF(cxh39,REF(CLOSE,1),DRAWNULL),0));cxh42:=CONST(SUM(IF(cxh40,REF(CLOSE,1),DRAWNULL),0));DRAWICON(cxh31 OR cxh37,CLOSE*1.001,39);DRAWICON(cxh32 OR cxh38,CLOSE*0.999,38);DRAWICON(cxh34 OR cxh40,REF(CLOSE,1)*0.9985,7);DRAWICON(cxh33 OR cxh39,REF(CLOSE,1)*1.0015,8);
{打工皇帝}N:=20;N1:=7;N2:=69;T1:=IF((DATE<=1341231),1,1);M3:=EMA(CLOSE,3);M6:EMA(CLOSE,6),COLOR008000,LINETHICK3;M12:EMA(M6,12),COLOR0000FF,LINETHICK3;cxh1:=EMA(M12,62);cxh2:=(CLOSE+HIGH+LOW)/(3);cxh3:=(EMA(cxh2,10))*(T1);cxh4:=(REF(cxh3,1))*(T1);STICKLINE((cxh3>cxh4),cxh3,cxh4,4,0),COLOR00FFFF;STICKLINE((cxh3<cxh4),cxh3,cxh4,4,0),COLORFF0000;cxh5:=((REF(HIGH,1)+REF(LOW,1))/(2))*(T1);cxh6:=MA(CLOSE,N)+((2)*(STD(CLOSE,N)))*(T1);DRAWTEXT(CROSS(cxh3,cxh4),(cxh3)*(0.98),''),COLOR00FFFF;DRAWTEXT(CROSS(cxh5,cxh6),(HIGH)*(1.04),'↓卖'),COLOR008000;cxh7:=REF(CLOSE,1);cxh8:=((SMA(MAX(CLOSE-cxh7,0),N1,1))/(SMA(ABS(CLOSE-cxh7),N1,1)))*(100);cxh9:=CROSS(N2,cxh8);cxhA:=(FILTER(cxh9,4))*(T1);DRAWTEXT(cxhA,(HIGH)*(1.04),'↓卖'),COLORFFFFFF;cxhB:=((2)*(CLOSE)+HIGH+LOW)/(4);cxhC:=LLV(LOW,34);cxhD:=HHV(HIGH,34);cxhE:=(EMA(((cxhB-cxh1)/(cxh5-cxh1))*(100),7))*(T1);cxhF:=(EMA((0.667)*(REF(cxhE,1))+(0.333)*(cxhE),5))*(T1);DRAWTEXT(IF(((COUNT((CLOSE<REF(CLOSE,1)),6))/(6)>0.6) AND (VOL>=(1.5)*(MA(VOL,5))) AND COUNT((cxhE>=cxhF),3) AND (REF(LOW,1)=LLV(LOW,120)),1,0),LOW,'●买进'),COLORFF00FF;DRAWTEXT(IF(((COUNT((CLOSE<REF(CLOSE,1)),12))/(12)>0.6) AND COUNT((cxhE>cxhF),6) AND (REF(LOW,5)=LLV(LOW,120)) AND REF((CLOSE>=OPEN),4) AND REF((CLOSE>OPEN),3) AND REF((CLOSE>OPEN),2) AND REF((OPEN>CLOSE),1) AND (OPEN>REF(CLOSE,1)),1,0),LOW,'●买进'),COLOR00FFFF;cxh10:=(MA(CLOSE,80)-(MA(CLOSE,10))/(3))*(T1);DRAWTEXT(IF((CLOSE<cxh10) AND ((VOL)/(240)>(MA(VOL,5))/(240)) AND (CLOSE>(REF(CLOSE,1))*(1.08)) AND (CLOSE<(MA(CLOSE,12))*(1.3)),1,0),LOW,'●抄底'),COLOR0000FF;

 

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

 

 

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

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

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

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

 


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

相关文章

    没有相关内容