1、强弱度一级行业,来源原理和使用解释 公式的来源原理和使用解释: 本公式选取通达信,一级行业分类指数,基于强弱度RSI公式数值,来分析板块强弱度,寻找领涨市场的板块或是先于市场提前见底板块。 同理:也可利用各种行业和概念题材板块指数,或是多个股组合形成强弱度的点击模型,只要把对应名称和代码进行更改即可。 RSI参数1的大小会影响图形显示,可根据短长偏好进行RSI参数1的设置。同时考虑到线性光滑,进行了EMA 5日的处理。 代码如下: LC:=REF(CLOSE,1); 当前:EMA(SMA(MAX(CLOSE-LC,0),10,1)/SMA(ABS(CLOSE-LC),10,1)*100,5),DOTLINE,COLORYELLOW; 能源:EMA(CALCSTOCKINDEX('SH880981','RSI',1),5); 材料:EMA(CALCSTOCKINDEX('SH880982','RSI',1),5); 消费:EMA(CALCSTOCKINDEX('SH880983','RSI',1),5); 可选:EMA(CALCSTOCKINDEX('SH880984','RSI',1),5); 商贸:EMA(CALCSTOCKINDEX('SH880985','RSI',1),5); 服务:EMA(CALCSTOCKINDEX('SH880986','RSI',1),5); 制造:EMA(CALCSTOCKINDEX('SH880987','RSI',1),5); 公用:EMA(CALCSTOCKINDEX('SH880988','RSI',1),5); 交运:EMA(CALCSTOCKINDEX('SH880989','RSI',1),5); 金融:EMA(CALCSTOCKINDEX('SH880990','RSI',1),5); 建设:EMA(CALCSTOCKINDEX('SH880991','RSI',1),5); 信息:EMA(CALCSTOCKINDEX('SH880992','RSI',1),5); 综企:EMA(CALCSTOCKINDEX('SH880993','RSI',1),5); 2、8年打造指标 八年打造指标( 股 民 学 院 : http://www.58188.com ) 本公式,自用多年,感觉还不错,没未来函数。 {8年打造指标} DRAWGBK(C>0,RGB(0,150,150),RGB(0,00,100),0,' ',0),LINETHICK2; {(1)保险稳健参数设:13.3.3; (2)短线参数设:19.3.3; (3)牛市参数设:34.3.3; (4)兔市参数设:55.3.3,; (5)熊市参数设:89.3.3; } SS:=19; HP:=HHV(H,SS); LP:=LLV(L,SS); R:=(C-LP)/(HP-LP)*100; K:SMA(R,3,1),COLORYELLOW,LINETHICK2; D:SMA(K,3,1),COLORWHITE,LINETHICK2; J:3*K-2*D,COLORFF9999,LINETHICK2; DRAWBAND(K,RGB(200,50,55),D,RGB(50,100,10)); M:=MA(R,40); S:=STD(R,40); 高:=M+2*S; 中:=M; 低:=M-2*S; 【高】: 高,COLOR0099FF; 【中】: 中,POINTDOT,COLORWHITE; 【低】: 低,COLOR00FF00; DRAWTEXT(CROSS(高,J) ,J*1.2,'★'),COLORYELLOW; DRAWTEXT(CROSS(中,J) AND M<=80 ,高,'高抛'),COLORRED; DRAWTEXT(CROSS(J,低) ,J,'▲'),COLOR00FF00; DRAWTEXT(CROSS(J,低) AND K<10 ,J,'▲'),COLORRED; DRAWTEXT(CROSS(J,中) AND K>D ,K-0.05,'低吸'),COLORYELLOW; DRAWTEXT(CROSS(D,K) AND (D>M OR D>=50),D,'★'),COLORYELLOW; DRAWTEXT(CROSS(D,K) AND M>80,高,'逃顶'),COLORYELLOW; DRAWTEXT(CROSS(D,K) AND D>85,D,'★'),COLORRED; DRAWTEXT(CROSS(K,D) AND D<15,D,'▲'),COLORRED; DRAWTEXT(中>80 ,中,'★'),COLORRED; 3、超强短线 操作:=MA(C,3); HHV(操作,15),LINETHICK1,COLORYELLOW,DOTLINE; K线分界:HHV(操作,15),LINETHICK1,COLORYELLOW,DOTLINE; DRAWTEXT(ISLASTBAR,K线分界,STRCAT('K线分界:',CON2STR(K线分界,2))),COLORYELLOW; {半黄K买绿不参} VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2); VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2); VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2); VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2); VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1; STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),3.1,0),COLOR00FFFF;{00D900黄色} DRAWTEXT(VAR19,L-0.11,'黄'),COLOR00FFFF; DRAWTEXT(VAR19,L-0.17,'买'),COLOR00FFFF; VAR1PP:=REF(C,1); VAR15PP:=SMA(MAX(C-VAR1PP,0),7,1)/SMA(ABS(C-VAR1PP),7,1)*100; STICKLINE(CROSS(78,VAR15PP),C,O,2,0) ,COLOR00FF00,LINETHICK1; DRAWTEXT(CROSS(78,VAR15PP),H+0.18,'止') ,COLOR00FF00; DRAWTEXT(CROSS(78,VAR15PP),H+0.07,'赢') ,COLOR00FF00; VAR2HH:=IF(CLOSE>OPEN,CLOSE,OPEN); VAR3HH:=REF(VAR2HH,BARSLAST(VOL=HHV(VOL,60))); 韭菜点:=(LOW<=REF(VAR3HH,1)*0.6 AND REF(LOW,1)>REF(VAR3HH,1)*0.6 AND REF(LOW,2)>REF(VAR3HH,1)*0.6 AND REF(LOW,3)>REF(VAR3HH,1)*0.6),COLORGREEN; STICKLINE(韭菜点,C,O,3,0),COLORLIRED; STICKLINE(韭菜点,H*1.1,L-0.15,0,0),COLORLIRED; DRAWTEXT(韭菜点,L-0.05,'韭菜'),COLORLIRED; 波段底:=(3)*(SMA(((CLOSE - LLV(LOW,27))/(HHV(HIGH,27) - LLV(LOW,27)))*(100),5,1)) - (2)*(SMA(SMA(((CLOSE - LLV(LOW,27))/(HHV(HIGH,27) - LLV(LOW,27)))*(100),5,1),3,1)); DRAWTEXT(CROSS(波段底,3),L-0.04,'底'); {抛一半} 买卖:=(EMA(C,3.14)+EMA(C,6.28))/2,COLORRED,NODRAW; 吸:=买卖*0.935,COLORWHITE,NODRAW; 抛:=买卖*1.075,COLORYELLOW,NODRAW; DRAWTEXT(L<买卖*0.935,L*0.99,'吸1/5')COLORYELLOW; DRAWTEXT(L<买卖*0.935,L*0.98,'反弹出')COLORYELLOW; DRAWTEXT(H>买卖*1.075 AND C/REF(C,1)<1.091,H*1.015,'抛一半'),COLORWHITE; DRAWTEXT(H>买卖*1.075 AND C/REF(C,1)<1.091,H*1.007,'再低吸'),COLORWHITE; |