通达信【趋势动力】主副图 精确交易买卖时机 量化评分 指标源码

{量能动力副图源码如下}


HGW1:=SUM(MAX(MAX(H-L,ABS(H-REF(C,1))),ABS(REF(C,1)-L)),14);
HGW2:=HIGH-REF(HIGH,1);
HGW3:=REF(LOW,1)-LOW;
HGW4:=SUM(IF(HGW2>0 AND HGW2>HGW3,HGW2,0),14);
HGW5:=SUM(IF(HGW3>0 AND HGW3>HGW2,HGW3,0),14);
HGW6:=HGW4*100/HGW1;
HGW7:=HGW5*100/HGW1;
HGW8:=(HGW6-HGW7);
HGW48:=HGW8>=0;
HGW49:=(HGW6-HGW7);
STICKLINE(HGW48,0,HGW8,3,0),COLOR000055;
STICKLINE(HGW48,0,HGW8,2.8,0),COLOR000066;
STICKLINE(HGW48,0,HGW8,2.5,0),COLOR000077;
STICKLINE(HGW48,0,HGW8,2.2,0),COLOR000088;
STICKLINE(HGW48,0,HGW8,1.7,0),COLOR000099;
STICKLINE(HGW48,0,HGW8,1.2,0),COLOR0000AA;
STICKLINE(HGW48,0,HGW8,0.7,0),COLOR0000CC;
STICKLINE(HGW48,0,HGW8,0.2,0),COLOR0000FF;
STICKLINE(HGW49<0,0,HGW49,3,0),COLOR009900;
STICKLINE(HGW49<0,0,HGW49,2,0),COLOR00BB00;
STICKLINE(HGW49<0,0,HGW49,1,0),COLOR00DD00;
STICKLINE(HGW49<0,0,HGW49,0.3,0),COLOR00FF00;


{趋势动力主源码如下}

HGW1:=(EMA(CLOSE,10)*7+EMA(CLOSE,20)*3)/10;
HGW2:=DMA(EMA(CLOSE,20),MAX(1,100*(SUM(VOL,5)/(3*CAPITAL))));
HGW3:=(CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2));
HGW4:=(REF(HGW3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW5:=(REF(HGW4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW6:=(REF(HGW5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW7:=(REF(HGW6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW8:=(REF(HGW7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW9:=(REF(HGW8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW10:=(REF(HGW9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW11:=(REF(HGW10,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW12:=(REF(HGW11,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW13:=(REF(HGW12,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW14:=(REF(HGW13,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW15:=(CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2));
HGW16:=(REF(HGW15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW17:=(REF(HGW16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW18:=(REF(HGW17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW19:=(REF(HGW18,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW20:=(REF(HGW19,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW21:=(REF(HGW20,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW22:=(REF(HGW21,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW23:=(REF(HGW22,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW24:=(REF(HGW23,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW25:=(REF(HGW24,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
HGW26:=(REF(HGW25,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
HGW27:=HGW15 OR HGW16 OR HGW17 OR HGW18 OR HGW19 OR HGW20;
HGW28:=HGW27 OR HGW21 OR HGW22 OR HGW23 OR HGW24 OR HGW25;
HGW29:=((REF(HGW28 OR HGW26,1)) AND HGW3);
HGW30:=HGW3 OR HGW4 OR HGW5 OR HGW6 OR HGW7 OR HGW8 OR HGW9;
HGW31:=HGW30 OR HGW10 OR HGW11 OR HGW12 OR HGW13;
HGW32:=((REF(HGW31 OR HGW14,1)) AND HGW15);
HGW33:=HGW3 OR HGW4 OR HGW5 OR HGW6 OR HGW7 OR HGW8 OR HGW9;
红色持股:HGW33 OR HGW10 OR HGW11 OR HGW12 OR HGW13 OR HGW14,COLOR0000FF,NODRAW;
HGW34:=IF(红色持股,LLV(CLOSE,2),DRAWNULL);
HGW35:=HGW15 OR HGW16 OR HGW17 OR HGW18 OR HGW19 OR HGW20 OR HGW21;
今离场价:REF(HGW34,1),COLOR0000FF,NODRAW;
青色观望:HGW35 OR HGW22 OR HGW23 OR HGW24 OR HGW25 OR HGW26,COLORFFFF00,NODRAW;
HGW36:=IF(青色观望,HHV(CLOSE,2),DRAWNULL);
HGW37:=(HIGH+LOW+OPEN+2*CLOSE)/5;
HGW38:=2*HGW37-HIGH;
HGW39:=HGW37-(HIGH-LOW);
HGW40:=IF(MA(CLOSE,5)>MA(CLOSE,10),20,0);
HGW41:=IF(MA(CLOSE,20)>MA(CLOSE,60),10,0);
HGW42:=IF(KDJ.J>KDJ.K,10,0);
HGW43:=IF(MACD.DIF>MACD.DEA,10,0);
HGW44:=IF(MACD.MACD>0,10,0);
HGW45:=IF(VOL>MA(VOL,60),10,0);
HGW46:=IF(WINNER(CLOSE)>0.5,10,0);
HGW48:=IF(CLOSE/REF(CLOSE,1)>1.03,10,0);
HGW49:=HGW40+HGW41+HGW42+HGW43+HGW44+HGW45+HGW46+HGW48;
今进场价:REF(HGW36,1),COLORFF0000,NODRAW;
短买:HGW29,COLOR33AACC,NODRAW;
白色离场:HGW32,COLORFF99FF,NODRAW;
急速超跌:(CLOSE-MA(CLOSE,34))/MA(CLOSE,34)*100<-14,COLORFFFFFF,NODRAW;
上市日期年:REF(YEAR,BARSCOUNT(CLOSE)-1),NODRAW,COLOR0000FF;
月:REF(MONTH,BARSCOUNT(CLOSE)-1),NODRAW,COLORFF00FF;
日:REF(DAY,BARSCOUNT(CLOSE)-1),NODRAW,COLOR00FFFF;
DRAWTEXT_FIX(C!=0,0.90,0.88,0,STRCAT('支撑:',STRCAT(CON2STR(HGW38,2),' 元'))),COLORRED;
DRAWTEXT_FIX(C!=0,0.90,0.96,0,STRCAT('反转:',STRCAT(CON2STR(HGW39,2),' 元'))),COLORYELLOW;
DRAWTEXT_FIX(V>O,0.90,0.80,0,STRCAT('量化评分:',STRCAT(CON2STR(HGW49,2),' '))),COLORFFFFFF;
DRAWBAND(HGW1,RGB(255,50,50),HGW2,RGB(64,204,208));


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

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

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