当前位置: 网站首页 > 股票软件公式 > 通达信公式 > 文章 当前位置: 通达信公式 > 文章

通达信源码:好多宝,抄底王,牛熊分界线

点击: 次    来源:顶尖财经    作者:股市狙击 - 小 + 大

1、好多宝,私藏的经典老公式,意外惊喜

本是一个多空筹码类的,认真看线,超级灵敏,买进卖出都很灵敏,看了下线的赋值原因,多窗口显示太小,如果配合大众抄底指标火焰山有什么后果呢,或者自己的系统主图呢,献上源码,希望大家可以认真观察那三条线,真有惊喜,希望大家拓展,有结果的大神希望接力,继续造福大众这个是私藏的经典老公式,意外惊喜,给大家分享(源码,无未来)

VAR1:=EMA(MA(IF(CLOSE>OPEN,(CLOSE-OPEN)*VOL,IF(CLOSE<OPEN,(CLOSE-OPEN)*VOL,0)),5),1);
VAR2:=EMA(MA(IF(CLOSE>REF(CLOSE,1),(CLOSE-REF(CLOSE,1))*VOL,IF(CLOSE<REF(CLOSE,1),(CLOSE-REF(CLOSE,1))*VOL,0)),5),1);
VAR3:=EMA(MA(IF(OPEN>REF(CLOSE,1),(OPEN-REF(CLOSE,1))*VOL,IF(OPEN<REF(CLOSE,1),(OPEN-REF(CLOSE,1))*VOL,0)),5),1);
VAR4:=EMA(MA(IF(CLOSE<OPEN,(OPEN-CLOSE)*VOL,IF(CLOSE>OPEN,(OPEN-CLOSE)*VOL,0)),10),1);
VAR5:=EMA(MA(IF(CLOSE<REF(CLOSE,1),(REF(CLOSE,1)-CLOSE)*VOL,IF(CLOSE>REF(CLOSE,1),(REF(CLOSE,1)-CLOSE)*VOL,0)),10),1);
VAR6:=EMA(MA(IF(OPEN<REF(CLOSE,1),(REF(CLOSE,1)-OPEN)*VOL,IF(OPEN>REF(CLOSE,1),(REF(CLOSE,1)-OPEN)*VOL,0)),10),1);
VAR7:=CLOSE>OPEN;
VAR8:=CLOSE>REF(CLOSE,1);
VAR9:=OPEN>REF(CLOSE,1);
多头:(VAR1+VAR2+VAR3)/3/100,COLORWHITE;
空头:(VAR4+VAR5+VAR6)/3/100,COLORYELLOW ;
一次警报:EMA(EMA((VAR1+VAR2+VAR3)/3-(VAR4+VAR5+VAR6)/3,5),5)*1/100,COLORMAGENTA;
二次警报:EMA((COUNT(VAR8,12)/12+COUNT(VAR7,12)/12+COUNT(VAR9,12)/12)/3*MA(多头,5)*2*1.1,2),COLORBLUE;
STICKLINE(空头>0,0,空头,1,0),COLORCYAN;
STICKLINE(空头<0,0,空头,1,0),COLORRED;
破解:EMA(EMA((VAR1+VAR2+VAR3)/3-(VAR4+VAR5+VAR6)/3,5),5)*1/100,POINTDOT,COLOR9587FF;{这句没有用处};
 


2、抄底王,红色持股,绿色持币,粉色反转,黄色洗盘

记得这个公式,是十多年前的经典指标了。( 顶尖财经 股票学院: http://www.58188.com )

{抄底王}
VAR2:=MA(CLOSE, 5);
VAR3:=MA(CLOSE, 10);
VAR4:=MA(CLOSE, 20);
VAR5:=MA(CLOSE, 30);
VAR6:=(VAR2+VAR3+VAR4+VAR5)/4;
VAR7:=(VAR6-REF(VAR6,15))/REF(VAR6, 15)*100;
VAR8:=(VAR6-REF(VAR6, 15))/REF(VAR6, 15)*100;
VAR9:=EMA(VAR7,8);
反转:STICKLINE(VAR9>1*REF(VAR9, 1), VAR7, 0, 2, 0), COLOREE00EE;
持股:STICKLINE(VAR7>1*REF(VAR7, 1), VAR7, VAR9, 2, 0), COLORRED;
持币:STICKLINE(VAR7<1*REF(VAR7, 1), VAR7, VAR9,4, 1), COLORGREEN;
洗盘:STICKLINE(VAR7<1*REF(VAR7, 1) AND VAR9>1*REF(VAR9, 1), VAR7, VAR9, 4, 0), COLOR00EEFF;
VAR10:=(CLOSE-MA(CLOSE, 58))/MA(CLOSE, 58)*100;
VAR11:=(VAR10>1*REF(VAR10, 1) AND VAR10<-26 AND VAR10>-40)*1.5;
VAR12:=VOL/CAPITAL*100;
VAR13:=LLVBARS(LOW, 50);
VAR14:=SUM(VOL, VAR13);
VAR15:=HHVBARS(HIGH, 50);
VAR16:=SUM(VOL, VAR15);
VAR17:=(CLOSE-REF(OPEN, VAR15))/REF(OPEN, VAR15)*100;
VAR18:=VAR16/CAPITAL*100;
VAR19:=(CLOSE-REF(OPEN, VAR13))/REF(OPEN, VAR13)*100;
VAR20:=VAR14/CAPITAL*100;
VAR21:=MA(CLOSE, 3);
VAR22:=REF(CLOSE, 2)*0.865;
VAR23:=REF(CLOSE, 13)*0.772;
VAR24:=MIN(VAR22, VAR23);
VAR25:=MA(CLOSE, 13);
抄底王:IF((CLOSE-VAR24)/CLOSE<0.030 AND VAR17<(-35) AND SUM(VAR12, 5)/5<1.800, 1, 0)*10, COLORWHITE,POINTDOT;
DRAWTEXT(抄底王, 抄底王, ' 底 追 '), COLORFFAA00;
VAR26:=(CLOSE-REF(CLOSE, 1))/REF(CLOSE, 1)*100;
VAR27:=(EMA(CLOSE, 12)-EMA(CLOSE, 26))*100;
VAR28:=EMA(VAR27, 9);
VAR29:=2*(VAR27-VAR28);
DRAWTEXT(VAR27<(-50) AND VAR26>7 AND VAR27<VAR28, (-10), '底'), COLORWHITE;
DRAWTEXT(VAR27<(-50) AND VAR26>7 AND VAR27>=VAR28, 5, '追'), COLORWHITE;
STICKLINE(VAR27<(-50) AND VAR26>7, 0,(-10), 5, 0), COLORFFFF66;
{红色持股,绿色持币,粉色反转,黄色洗盘. };



3、牛熊分界线

DRAWGBK(1,RGB(1,1,1),RGB(1,1,1),0,'00',0);

VA1:=HHV(HIGH,9)-LLV(LOW,9); 
VA2:=HHV(HIGH,9)-CLOSE;
VA3:=CLOSE-LLV(LOW,9);
VA4:=VA2/VA1*100-70;
VA5:=(CLOSE-LLV(LOW,60))/(HHV(HIGH,60)-LLV(LOW,60))*100;
VA6:=(CLOSE+HIGH+LOW)/3;
VA7:=SMA(VA3/VA1*100,3,1);
VA8:=LLV(LOW,34);
VA9:=SMA(VA7,3,1)-SMA(VA4,9,1);
VARA:=IF(VA9>100,VA9-100,0);
VARB:=HHV(HIGH,34);
VARC:=EMA((VA6-VA8)/(VARB-VA8)*100,13);
VARD:=EMA(0.667*REF(VARC,1)+0.333*VARC,2);
VARE:=SMA(MAX(CLOSE-REF(CLOSE,1),0)/CLOSE,8,1)/SMA(ABS(INDEXC-REF(INDEXC,1))/INDEXC,8,1)*100-25;
VARF:=MA(VARE,3);
VAR1:=HHV(HIGH,9)-LLV(LOW,9);
VAR2:=HHV(HIGH,9)-CLOSE;
VAR3:=CLOSE-LLV(LOW,9);
VAR4:=((VAR2)/(VAR1))*(100)-70;
VAR5:=((CLOSE-LLV(LOW,60))/(HHV(HIGH,60)-LLV(LOW,60)))*(100);
VAR6:=((2)*(CLOSE)+HIGH+LOW)/(4);
VAR7:=SMA(((VAR3)/(VAR1))*(100),3,1);
VAR8:=LLV(LOW,34);
VAR9:=SMA(VAR7,3,1)-SMA(VAR4,9,1);
VAR10:=IF((VAR9>100),VAR9-100,0);
VAR11:=HHV(HIGH,34);
B1:=EMA(((VAR6-VAR8)/(VAR11-VAR8))*(100),8);
DRAWKLINE(EMA(B1,5),EMA(B1,5),B1+1,B1);
领先:EMA(B1,5),COLORCYAN;
生命线:EMA(VARD,1),COLORYELLOW;
V1:=MA(C,5)=HHV(MA(C,5),20);
V2:=MA(C,5)>MA(C,10);
V3:=MA(V,5)>MA(V,40)*1.01;
V4:=COUNT(MA(C,1)>REF(C,1),2)=2;
VV:=V1 AND V2 AND V3 AND V4;
A1:=EMA(CLOSE,8);
A2:=EMA(A1,20);
A3:=CROSS(A1,A2);
A4:=A1<EMA(CLOSE,120);
STICKLINE((A3 AND A4)OR(V1 AND V2 AND V3 AND V4),B1*1.03,B1*1.120,1,0),COLORYELLOW;
A5:=3*SMA((CLOSE-LLV(LOW,18))/(HHV(HIGH,18)-LLV(LOW,18))*100,21,1)-2*
SMA(SMA((CLOSE-LLV(LOW,18))/(HHV(HIGH,18)-LLV(LOW,18))*100,20,1),8,1),CIRCLEDOT ,COLORFF9900 ;
安全位:=20;
低位转强:IF(CROSS(A5,安全位),50,0),STICK,COLORMAGENTA,LINETHICK2;
开始拉升:IF(CROSS(VARC,生命线) AND VARC>VARD AND VARC<55 AND C>O,50,0),
COLORLIRED,POINTDOT;
A6:=LLV(C,500)=LLV(C,5) AND C/REF(C,1)>(1+9.8/100);
极地上涨:IF(A6,领先,0),COLORGREEN,LINETHICK2;
STICKLINE(开始拉升>0,15,开始拉升*1.01,1,0),COLORBLUE;
STICKLINE((开始拉升>0 AND 开始拉升<400) OR (极地上涨>0 AND 极地上涨<400)
OR (低位转强>0 AND 低位转强<400) OR (低位转强>0),30,开始拉升,1,0),COLORRED;
STICKLINE(开始拉升>0,15,开始拉升*0.6,3,0),COLORBLUE;
STICKLINE(开始拉升>0,15,开始拉升*0.4,3,0),COLOR00FF00;
STICKLINE(开始拉升>0,15,开始拉升*0.2,3,0),COLOR0099CC;
STICKLINE(低位转强>0,15,低位转强*1.01,1,0),COLORMAGENTA;
STICKLINE((低位转强>0)OR(极地上涨>0),15,低位转强*0.4,3,0),COLORYELLOW;
STICKLINE(低位转强>0,15,低位转强*0.2,3,0),COLORFFCC66;
STICKLINE(极地上涨>0,15,极地上涨*1.01,1,0),COLORYELLOW;

上一篇:通达信源码:波段点睛王,优化版CCI,博尔量化

下一篇:通达信源码:出单OR止损公式,精准抓妖,智能MACD