{================背景 ================}; DRAWGBK(ISLASTBAR, RGB(60,60,60),RGB(0,0,0),0,'0',0);
PJGJ:=AMOUNT/VOL/100;
SSRYDJX:=MA(PJGJ,13);
SSRCJL:=EMA(VOL,13);
SSRCJE:=EMA(AMOUNT,13);
SSRCBJX:=SSRCJE/SSRCJL/100;
CYS13:=(CLOSE-SSRCBJX)/SSRCBJX*100;
XYSHSL:=EMA(VOL/CAPITAL*100,13);
STICKLINE(XYSHSL>6.1 AND CYS13>5 ,20 ,0 ,1 ,0 ),COLORGREEN;
STICKLINE(XYSHSL>3.8 AND CYS13>5 ,15.30 ,0 ,2 ,0 ),COLORYELLOW;
STICKLINE(XYSHSL>2.1 AND CYS13>5 ,10 ,0 ,2 ,0 ),COLORCYAN;
STICKLINE(XYSHSL>1.8 AND CYS13>5 ,5.30 ,0 ,2 ,0 ),COLORBLUE;
RSVV1:=(CLOSE-LLV(LOW,7))/(HHV(HIGH,7)-LLV(LOW,7))*100;
RSVV2:=(9*SMA((CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*20,3,1)-3*SMA(SMA((CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*20,4,1),3,1)-SMA(SMA(SMA((CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*20,3,1),3,1),2,1));
RSVV:=(9*SMA((CLOSE-LLV(LOW,17))/(HHV(HIGH,17)-LLV(LOW,17))*20,3,1)-3*SMA(SMA((CLOSE-LLV(LOW,17))/(HHV(HIGH,17)-LLV(LOW,17))*20,4,1),3,1)-SMA(SMA(SMA((CLOSE-LLV(LOW,17))/(HHV(HIGH,17)-LLV(LOW,17))*20,3,1),3,1),2,1));
短K:SMA(RSVV,2,1),COLORAACCDD;
短D:SMA(短K,2,1),COLORYELLOW;
STICKLINE(短K>短D,短K,短D,1,0),COLORRED;
STICKLINE(短K<=短D,短K,短D,1,0),COLORYELLOW;
{趋势线}
去除ST:=IF(NAMELIKE('ST'),0,1) AND IF(NAMELIKE('*ST'),0,1);
去除停牌:=DYNAINFO(4)>0;
XG:=去除ST AND 去除停牌;
RSV1:=(CLOSE-LLV(LOW,9))/(HHV(HIGH,9)-LLV(LOW,9))*100;
FATK:=SMA(RSV1,5,1);
趋势线:=SMA(FATK,5,1);
买卖线:=(7*SMA((CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*30,4,1)-3*SMA(SMA((CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*30,4,1),3,1)-SMA(SMA(SMA((CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*30,4,1),3,1),2,1));
买卖线1:=(ATAN((MA(买卖线,4)/REF(MA(买卖线,4),1)-1)*100)*180/3.1416);
趋势线3:=(ATAN((MA(趋势线,4)/REF(MA(趋势线,4),1)-1)*100)*180/3.1416);
{角度MA20:=ATAN((MA20/REF(MA20,2)-1)*100)*180/3.1416;
角度MA34:=ATAN((MA34/REF(MA34,2)-1)*100)*180/3.1416;
角度MA55:=ATAN((MA55/REF(MA55,2)-1)*100)*180/3.1416;}
选股:=买卖线1>=86 AND 趋势线3>=30 ;
{选股2:=角度MA13>=45 AND 角度MA20>=10 AND 角度MA20<40 AND 角度MA34>=-10;
选股3:=角度MA13<0 AND 角度MA20<0;
选股55:=角度MA55<30 AND 角度MA55>=15;}
低位金叉:=CROSS(买卖线,趋势线) AND 趋势线<趋势位;
JCCOUNT:=COUNT(CROSS(买卖线,趋势线),BARSLAST(趋势线>=位置));
二次金叉:=CROSS(买卖线,趋势线) AND 趋势线<70 AND COUNT(JCCOUNT=2,21)=1;
三次金叉:=CROSS(买卖线,趋势线) AND 趋势线<75 AND 趋势线>30 AND COUNT(JCCOUNT=3,60)=1;
{TH1:=EVERY(峰谷2线<0 AND 峰谷1线<0,40);
TH2:=COUNT(CROSS(峰谷1线,峰谷2线),60)>=3;}
A1:=BARSLAST(REF(CROSS(买卖线,趋势线),1));
底背离:=REF(CLOSE,A1+1)>CLOSE AND 趋势线>REF(趋势线,A1+1) AND CROSS(买卖线,趋势线);
底背离1:=IF (背离>=1,底背离,1);
XXXX:= 选股 AND 低位金叉 AND XG;
GGG := 选股 AND 底背离 AND 二次金叉 AND XG;
BBB1:= 选股 AND 底背离 AND 三次金叉 AND XG;
STICKLINE(FILTER(选股 AND 三次金叉 AND XG AND 底背离1,3),0,50,1,0),COLOR0080FF;
DRAWTEXT(FILTER(选股 AND 三次金叉 AND XG AND 底背离1,3),52,'3'),COLORRED;
STICKLINE(FILTER(选股 AND 二次金叉 AND XG AND 底背离1,3),0,40,1,0),COLOR00FFFF;
DRAWTEXT(FILTER(选股 AND 二次金叉 AND XG AND 底背离1,3),55,'2'),COLORRED;
STICKLINE(FILTER(选股 AND 低位金叉 AND XG AND 底背离1,3),0,30,1,0),COLORFF8000;
DRAWTEXT(FILTER(选股 AND 低位金叉 AND XG AND 底背离1,3),57,'1'),COLORRED;
{一绝}
Q_1:=C-REF(C,1);
Q_2:=100*EMA(EMA(Q_1,6),6)/EMA(EMA(ABS(Q_1),6),6);
Q_3:=CROSS(EMA(C,19),EMA(C,7));
Q_4:=CROSS(EMA(C,7),EMA(C,19));
ZD1:=L=LLV(L,BARSLAST(Q_3)+1);
ZD2:=LLV(L,BARSLAST(Q_3)+1);
ZD3:=H=HHV(H,BARSLAST(Q_4)+1);
ZD4:=HHV(H,BARSLAST(Q_4)+1);
Q_A:=DRAWLINE(ZD1,ZD2,ZD3,ZD4,0);
U111:=H=HHV(H,BARSLAST(Q_4)+1);
U222:=HHV(H,BARSLAST(Q_4)+1);
U333:=L=LLV(L,BARSLAST(Q_3)+1);
U444:=LLV(L,BARSLAST(Q_3)+1);
Q_B:=DRAWLINE(U111,U222,U333,U444,0);
TJ:=IF(Q_B<REF(Q_B,1) AND Q_B=Q_A,1,0);
BB11:=REF(TJ,1)=0 AND TJ>=1;
DRAWICON(BB11,55,7);
SS:=REF(Q_A<REF(Q_A,1) AND Q_B=Q_A,1)=0 AND TJ<1;
DRAWICON(SS,55,8);
{买卖点 卖出指标参考 副图}
{N 1 100 2 M 1 100 3}
{以下设置逃顶指标"MACD卖出"}
DIF:=EMA(EMA(EMA(CLOSE,5),5),5);
DEA:=EMA(EMA(EMA(CLOSE,7),7),7);
CDMA:=(DIF-DEA)*5;
MACD2:=CDMA;
MACD1:=CDMA;
低位反转:=MACD1<0 AND MACD1>REF(MACD1 ,1) AND REF(MACD1 ,1)<REF(MACD1 ,2)AND REF(MACD1 ,2)<REF(MACD1 ,3)AND REF(MACD1 ,3)<REF(MACD1 ,4);
STICKLINE(低位反转,0,MACD1,0.3,0),COLORRED;
高位反转:=MACD1>0 AND MACD1<REF(MACD1 ,1) AND REF(MACD1 ,1)>REF(MACD1 ,2)AND REF(MACD1 ,2)>REF(MACD1 ,3)AND REF(MACD1 ,3)>REF(MACD1 ,4);
STICKLINE(高位反转,0,MACD1,0.3,0),COLORGREEN;
VAR11:=SMA(MAX(C-REF(C,1),0),6,1)/SMA(ABS(C-REF(C,1)),6,1)*100;
DRAWICON(高位反转,40,92);
DRAWICON(低位反转,40,42);
VAR12:=REF(C,1);
VAR13:=SMA(MAX(C-VAR12,0),6,1)/SMA(ABS(C-VAR12),6,1)*100;
DRAWTEXT(CROSS(84,VAR13),50,'×'),COLORGREEN ;
{以下设置"精确卖出"}
{N 1 100 2 M 1 100 3}
VAR2:=1;
VAR3:=REF(HIGH,1)*1.1;
VAR4:=HIGH*1.1;
VAR5:=(VAR4*VOL+VAR3*(CAPITAL-VOL))/CAPITAL;
VAR6:=REF(LOW,1)*0.9;
VAR7:=LOW*0.9;
VAR8:=(VAR7*VOL+VAR6*(CAPITAL-VOL))/CAPITAL;
VAR9:=EMA(VAR8,30);
VARA:=EMA(VAR5,30);
VARB:=VARA-2;
VARC:=IF(CLOSE<=VAR9,VARB,VARA);
VARD:=MA(CLOSE,80)-MA(CLOSE,10)/17;
买点: STICKLINE(VARC-VARB=0 AND VAR2 AND CROSS((EMA(EMA(EMA(CLOSE,N),N),N)-REF(EMA(EMA(EMA(CLOSE,N),N),N),1))/REF(EMA(EMA(EMA(CLOSE,N),N),N),1)*100,MA((EMA(EMA(EMA(CLOSE,N),N),N)-REF(EMA(EMA(EMA(CLOSE,N),N),N),1))/REF(EMA(EMA(EMA(CLOSE,N),N),N),1)*100,M)),0,30,2,0),COLORRED;
写字: DRAWTEXT(FILTER(VARC-VARB=0 AND CROSS((EMA(EMA(EMA(CLOSE,N),N),N)-REF(EMA(EMA(EMA(CLOSE,N),N),N),1))/REF(EMA(EMA(EMA(CLOSE,N),N),N),1)*100,MA((EMA(EMA(EMA(CLOSE,N),N),N)-REF(EMA(EMA(EMA(CLOSE,N),N),N),1))/REF(EMA(EMA(EMA(CLOSE,N),N),N),1)*100,M)),4),45,'买'),COLORRED;
VARE:=(CLOSE-LLV(LOW,34))/(HHV(HIGH,34)-LLV(LOW,34))*100;
卖出线:=SMA(SMA(VARE,3,1),3,1);
买入线:=3*SMA(VARE,3,1)-2*卖出线;
DRAWICON(CROSS(90,买入线),25,2);
卖出: DRAWTEXT(FILTER(CROSS(90,买入线),3),26,'卖'),COLORGREEN;
{以下设置"买卖点"的买点}
VAR4A:=((C-LLV(L,21))/(HHV(H,21)-LLV(L,21)))*100;
VAR5A:=SMA(VAR4A,13,8);
VAR8A:=EMA(C,5);
VAR9A:=MA((LLV(C,9))*1.1,14);
VAR10A:=2*VAR9A-VAR8A-C*0.1;
VAR11A:=IF(((VAR8A-VAR10A)*5>0),(POW((VAR8A-VAR10A)*5,2))/10,(-1*(POW((VAR8A-VAR10A)*
(5),2)))/(10));
VAR12 |
评论内容只代表网友观点,与本站立场无关!
本网提供的公式文件说明:
* alg格式飞狐股票公式,可以用飞狐交易师或者交易师软件导入;
* fnc格式大智慧新一代公式指标,可以用大智慧股票软件使用,少部分可以用分析家股票软件引入使用;
* exp格式大智慧经典版股票公式,仅可以用大智慧经典版股票软件引入使用;
* tni和tnc格式通达信股票公式,仅可以用通达信新引入使用,例如可以用通达信股票软件引入使用;
* tne,tn6格式通达信公式,可以用通达信公式编辑器5.0版导入,推荐通达信金融终端版本;
* hxf格式同花顺股票公式,仅可以用同花顺股票软件引入使用。
以上的各种软件都可以在本网股票软件栏目找到!
* 关于股票公式时间限制,如果在引入大智慧公式,交易师公式或者飞狐公式的时候,发现公式名称栏是空白的,这时候调整电脑时间到1997年,又能出现公式名称,并且能正常显示,可能是公式使用期限已过。
* 关于还原公式源码如果你忘记了自己编写的大智慧公式,通达信公式,同花顺公式,操盘手公式,飞狐公式,博易大师公式,金字塔公式,文华公式和交易师公式等等公式的密码,本网可帮恢复源码,有.偿.服.务无意勿扰,点击在线咨询联系我。
* 关于股票公式源码编辑
本网提供的源码,一般都可以编辑成公式,如果不明白公式的编辑,在本页右侧教程录像可参考,或者找公式教程资料学习,请搜索:教程
* 如果您发现软件内容或者链接错误,请点击报告错误谢谢!
* 站内提供的所有软件包含源码均是由网上搜集,若侵犯了你的版权利益,请联系通知我们!