编写要求:
请高手看一下<探底>指标中有未来函数吗?
指标源码如下:
VARTIME:=IF(YEAR>=9999 AND MONTH>=11 AND DAY>=07,0,1);
VARDTIME:=IF(YEAR=9999 AND MONTH=11 AND DAY=06,1,0);
QW1:=(HIGH+LOW+CLOSE*2)/4*VARTIME;
QW3:=EMA(QW1,10)*VARTIME;
QW4:=STD(QW1,10)*VARTIME;
QW5:=(QW1-QW3)*100/QW4*VARTIME;
QW6:=EMA(QW5,5)*VARTIME;
RK7:=EMA(QW6,10)*VARTIME;
涨:EMA(QW6,10)+100/2-5,LINETHICK1,COLORRED;
跌:EMA(涨,4),LINETHICK1,COLORFFFF34;
多线:IF(CROSS(涨,跌) AND 跌<-10,30,0),LINETHICK1,COLORFF00FF;
空线:IF(CROSS(跌,80),70,100),COLOR0099FF,LINETHICK1;
买1:EMA(跌,4)*VARTIME,COLORWHITE;
买2:EMA(买1,4)*VARTIME,COLORGREEN;
买M3:=EMA(买2,4)*VARTIME,COLORYELLOW;
买M4:=EMA(买M3,4)*VARTIME,COLORCC9900;
-10,POINTDOT,COLOR888888,LINETHICK2;
80,POINTDOT,COLOR888888,LINETHICK2;
STICKLINE(涨 REF(涨,1),涨,EMA(涨,3),3,0) ,COLOR0099FF;
STICKLINE(涨> REF(涨,1),涨,EMA(涨,3),2,0) ,COLOR00AAFF;
STICKLINE(涨> REF(涨,1),涨,EMA(涨,3),1,0) ,COLOR00BBFF;
DRAWICON(多线,30,1),COLORFF00FF;
DRAWICON(CROSS(跌,80),70,2),COLORGREEN;
DRAWTEXT(CROSS(涨,跌) AND 跌<20 AND 跌>-10,40,'买入'),COLORCCFF99;
DRAWTEXT(多线>0,-20,'看涨'),COLOR0000FF;
VAR822:=DMA(EMA(CLOSE,12),SUM(VOL,5)/3/CAPITAL)*VARTIME;
VAR883:=(CLOSE-VAR822)/VAR822*100*VARTIME;
VAR1:=MA(CLOSE,152);
VAR2:=MA(CLOSE,194);
VAR3:=VAR2+2*STD(CLOSE,170);
VAR4:=VAR1+2*STD(CLOSE,170);
顶:(CLOSE>VAR3)*13*10,COLORBLUE,LINETHICK2;
VAR6:=EMA(HHV(HIGH,500),21);
VAR7:=EMA(HHV(HIGH,250),21);
VAR8:=EMA(HHV(HIGH,90),21);
VAR9:=EMA(LLV(LOW,500),21);
VARA:=EMA(LLV(LOW,250),21);
VARB:=EMA(LLV(LOW,90),21);
VARC:=EMA((VAR9*0.96+VARA*0.96+VARB*0.96+VAR6*0.558+VAR7*0.558+VAR8*0.558)/6,21);
VARD:=EMA((VAR9*1.25+VARA*1.23+VARB*1.2+VAR6*0.55+VAR7*0.55+VAR8*0.65)/6,21);
VARE:=EMA((VAR9*1.3+VARA*1.3+VARB*1.3+VAR6*0.68+VAR7*0.68+VAR8*0.68)/6,21);
VARF:=EMA((VARC*3+VARD*2+VARE)/6*1.738,21);
VAR10:=REF(LOW,1);
VAR11:=SMA(ABS(LOW-VAR10),3,1)/SMA(MAX(LOW-VAR10,0),3,1)*100;
VAR12:=EMA(IF(CLOSE*1.35<=VARF,VAR11*10,VAR11/10),3);
VAR13:=LLV(LOW,30);
VAR14:=HHV(VAR12,30);
VAR15:=IF(MA(CLOSE,58),1,0);
VAR16:=EMA(IF(LOW<=VAR13,(VAR12+VAR14*2)/2,0),3)/618*VAR15;
VAR17:=IF(VAR16>50,50,VAR16)/3.82*6;
VAR18:=HHV(HIGH,30);
VAR19:=LLV(LOW,30);
NL:=EMA((CLOSE-VAR19)/(VAR18-VAR19)*100,5)/8*10,COLORYELLOW,LINETHICK2;
VAR1A:=(EMA(AMOUNT,5)/EMA(VOL,5)/100-EMA(AMOUNT,125)/EMA(VOL,125)/100)/(EMA(AMOUNT,5)/EMA(VOL,5)/100)<-0.4;
VAR1B:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;
VAR1C:=SMA(VAR1B,3,1);
VAR1D:=SMA(VAR1C,3,1);
VAR1E:=(-100)*(HHV(HIGH,52)-CLOSE)/(HHV(HIGH,52)-LLV(LOW,52));
VAR1F:=COUNT(VAR1A,5)>=1 AND (VAR1E<-99.9 OR VAR1D<15 AND VAR1C<12);
VAR21:=100*WINNER(CLOSE);
VAR22:=MA(VAR21,3);
VAR25:=SUM(IF(CLOSE>REF(CLOSE,1),1,0),0);
VAR26:=SUMBARS(VOL,CAPITAL);
VAR27:=IF(CLOSE>LLV(CLOSE,VAR26),1,-1)*IF(VAR25>LLV(VAR25,VAR26),1,-1);
VAR28:=COUNT(IF(VAR27=-1,1,0)=1,8)>2;
VAR29:=(CLOSE-DMA((3*HIGH+LOW+OPEN+2*CLOSE)/7,VOL/(SUM(AMOUNT,13)/(AMOUNT/VOL/100)/100)))/DMA((3*HIGH+LOW+OPEN+2*CLOSE)/7,VOL/(SUM(AMOUNT,13)/(AMOUNT/VOL/100)/100))*100<-18;
VAR2A:=(CLOSE-MIN(REF(CLOSE,5)*0.865,REF(CLOSE,21)*0.772))/CLOSE<0.01;
VAR2B:=VAR28 AND VAR29 AND VAR2A;
VAR2C:=VOL/CAPITAL>=0.02 AND VOL/CAPITAL<=0.2 AND OPEN=1.105;
VAR2D:=VAR2C AND COUNT(VAR2C,5)=1;
VAR2E:=VAR2B OR VAR2C;
VAR2F:=REF(CLOSE,1);
VAR30:=SMA(MAX(CLOSE-VAR2F,0),7,1)/SMA(ABS(CLOSE-VAR2F),7,1)*100;
VAR31:=SMA(MAX(CLOSE-VAR2F,0),13,1)/SMA(ABS(CLOSE-VAR2F),13,1)*100;
VAR32:=VAR30<20 AND VAR31<25;
VAR33:=VAR32;
VAR34:=SUM(IF(CLOSE>REF(CLOSE,1),VOL,IF(CLOSELLV(CLOSE,VAR26),1,-1);
VAR36:=IF(VAR34>LLV(VAR34,VAR26),1,-1);
VAR37:=VAR35*VAR36;
VAR38:=IF(VAR37=-1,1,0);
VAR3B:=(CLOSE-LLV(LOW,36))/(HHV(HIGH,36)-LLV(LOW,36))*100;
VAR3C:=SMA(VAR3B,3,1);
VAR3D:=SMA(VAR3C,3,1);
VAR3E:=SMA(VAR3D,3,1);
VAR3F:=CROSS(VAR3D,VAR3E) AND VAR3D<20;
VAR40:=CROSS(VAR3E,VAR3D) AND VAR3D>80;
VAR41:=5;
DRAWTEXT(CROSS(VAR41,NL),30,'★做底'),COLORWHITE;
VAR44:=REF(CLOSE,1);
VAR45:=SMA(MAX(CLOSE-VAR44,0),6,1)/SMA(ABS(CLOSE-VAR44),6,1)*100;
STICKLINE(CROSS(84,VAR45),0,VAR2*15+3,3,1),COLORGREEN;
DRAWTEXT(CROSS(84,VAR45),80,'防空警报'),COLORGREEN ,;
VAR47:=EMA(100*(CLOSE-LLV(LOW,100))/(HHV(HIGH,100)-LLV(LOW,100)),5);
VAR48:=(CLOSE-LLV(CLOSE,126))/(HHV(CLOSE,126)-LLV(CLOSE,126))*100;
VAR49:=EMA(CLOSE,2)-EMA(CLOSE,150);
VAR4A:=EMA(VAR49,100);
VAR4B:=2*(VAR49-VAR4A);
VAR4C:=POW(VAR4B,3)*0.1+POW(VAR4B,1);
VAR4D:=SQRT(SQRT(LOW*HIGH*OPEN*CLOSE));
VAR4E:=EMA(VAR4D*0.97,3);
VAR4F:=(HIGH+LOW+CLOSE)/3;
VAR50:=(VAR4F-MA(VAR4F,14))/(0.015*AVEDEV(VAR4F,14));
VAR51:=IF(VAR4B>0.1,VAR4C,0)*5;
VAR52:=LLV(HIGH,240);
VAR53:=100*(CLOSE-VAR52)/VAR52;
VAR54:=AMOUNT/VOL;
VAR55:=EMA((WINNER(CLOSE*1.1)-WINNER(CLOSE*0.9))*80,5);
VAR56:=INDEXC;
VAR57:=MA(VAR56,5);
VAR58:=MA(VAR56,20);
VAR59:=MA(VAR56,30);
VAR5A:=VAR59>VAR57*1.08 AND VAR58>VAR57*1.055;
VAR5B:=VAR57>VAR56*1.03 AND VAR58>VAR56*1.13;
VAR5C:=VAR5B;
VAR5D:=IF(FILTER(VAR55<6,5)=1,1,0);
VAR5E:=(VAR5D AND VAR53<-2.5 AND VAR47<5 AND VAR48=0)*60;
VAR5F:=VAR55<6 AND VAR5C;
VAR60:=IF(FILTER(VAR5F,1)=1,1,0)*80;
VAR61:=VAR5F AND VAR5D*80;
VAR62:=CROSS(VAR51,2);
VAR63:=CROSS(VAR51,4);
VAR64:=(CLOSE-MA(CLOSE,6))/MA(CLOSE,6)*100;
VAR65:=(CLOSE-MA(CLOSE,12))/MA(CLOSE,12)*100;
VAR66:=(CLOSE-MA(CLOSE,24))/MA(CLOSE,24)*100;
VAR67:=REF(CLOSE,1);
VAR68:=SMA(MAX(CLOSE-VAR67,0),5,1)/SMA(ABS(CLOSE-VAR67),5,1)*100;
VAR69:=(HIGH+LOW+CLOSE)/3;
VAR6A:=(VAR69-MA(VAR69,14))/(0.015*AVEDEV(VAR69,14));
VAR6B:=(VAR64>=-15.8 AND VAR64<=-12.2 AND VAR65<=-20.8 AND VAR66<=-27.5 AND VAR68<=11.7 AND VAR6A<=-145)*100;
VAR6C:=VAR48=0;
VAR6D:=VAR48=100;
VAR6E:=LLV(HIGH,240);
VAR6F:=100*(CLOSE-VAR6E)/VAR6E;
VAR70:=(CLOSE-LLV(LOW,528))/(HHV(HIGH,528)-LLV(LOW,528))*100;
VAR71:=(CLOSE-LLV(CLOSE,530))/(HHV(CLOSE,530)-LLV(CLOSE,530))*100;
VAR72:=0;
VAR73:=SMA(MAX(CLOSE-REF(CLOSE,1),0),34,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),7,1)*100;
VAR74:=SMA(MAX(CLOSE-REF(CLOSE,1),0),13,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),13,1)*100;
VAR75:=BARSCOUNT(CLOSE);
VAR76:=VAR73<20 AND VAR74<23 AND VAR75>35;
VAR77:=VAR76 AND COUNT(VAR76,1)=1;
VAR78:=EMA(CLOSE,21)-EMA(CLOSE,8);
VAR79:=EMA(VAR78,5);
VAR7A:=TROUGHBARS(3,6,1)<4 AND CROSS(VAR78,VAR79);
VAR7B:=IF(TROUGHBARS(3,16,1)=0 AND HIGH>LOW+0.04,4,0);
VAR7C:=IF(EMA(CLOSE,5)/EMA(EMA(CLOSE,9),16)<=0.85 AND CLOSE/REF(CLOSE,1)>0.905 AND CLOSE/REF(CLOSE,1)<1.05 AND VOL/CAPITAL*100<5,50,0);
VAR7D:=(-100)*(HHV(HIGH,34)-CLOSE)/(HHV(HIGH,34)-LLV(LOW,34))+100;
VAR7E:=(-100)*(HHV(HIGH,50)-CLOSE)/(HHV(HIGH,50)-LLV(LOW,50))+100;
VAR7F:=(-100)*(HHV(HIGH,70)-CLOSE)/(HHV(HIGH,70)-LLV(LOW,70))+100;
VAR80:=((CLOSE-MA(CLOSE,34))/MA(CLOSE,34)*100+10)*5;
VAR81:=((CLOSE-MA(CLOSE,50))/MA(CLOSE,50)*100+10)*5;
VAR82:=((CLOSE-MA(CLOSE,70))/MA(CLOSE,70)*100+10)*5;
VAR83:=(VAR7D+VAR7E+VAR7F+VAR80+VAR81+VAR82)/6;
VAR84:=EMA(VAR83,3);
VAR85:=ABS(VAR80-VAR82);
VAR86:=(VAR83+VAR85)/2;
VAR87:=(-1)*(EMA(100*(1-WINNER(CLOSE)),1)-50)+50;
VAR88:=VAR87+VAR86;
VAR89:=IF(VAR7C>0 AND VAR88<0,200,0);
VAR8A:=IF(VAR86<0 AND CLOSE=LLV(CLOSE,5) AND CLOSE/REF(CLOSE,1)>0.905 AND CLOSE/REF(CLOSE,1)<1.05 AND VOL/CAPITAL*100<5,-50,0);
VAR8B:=IF(VAR88<0 AND VAR8A=-50,100,0);
VAR8C:=MA(CLOSE,3);
VAR8D:=REF(CLOSE,2)*0.865;
VAR8E:=REF(CLOSE,13)*0.772;
VAR8F:=MIN(VAR8D,VAR8E);
VAR90:=100*VOL/CAPITAL;
VAR91:=MA(CLOSE,13);
VAR92:=IF((CLOSE-VAR8F)/CLOSE<0.03 AND SUM(VAR90,5)/5<1.8,1,0);
VAR93:=IF(VAR92>0 AND (VAR8A<0 OR VAR7C>0),100,0);
VAR94:=VAR93;
VAR95:=IF(VAR89>0 AND VAR8B>0 AND SUM(VOL/CAPITAL*100,5)/5<1 OR VAR92>0 AND REF(CLOSE,1)/REF(CLOSE,2)>0.902 OR (VAR89>0 AND VAR8B>0 AND SUM(VOL/CAPITAL*100,5)/5<1 OR VAR92>0) AND (VAR8A<0 OR VAR7C>0) AND VAR93<10,50,0);
VAR96:=(VAR89>0 AND VAR8B>0 AND SUM(VOL/CAPITAL*100,5)/5<1 OR VAR92>0) AND (VAR8A<0 OR VAR7C>0);
VAR97:=VAR89>0 AND VAR8B>0 AND SUM(VOL/CAPITAL*100,5)/5<1 OR VAR92>0 AND REF(CLOSE,1)/REF(CLOSE,2)>0.902;
VAR98:=VAR96 OR VAR97;
VAR99:=SMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(LOW-REF(CLOSE,1))),14,1);
VAR9A:=HIGH-REF(HIGH,1);
VAR9B:=REF(LOW,1)-LOW;
VAR9C:=SMA(IF(VAR9A>0 AND VAR9A>VAR9B,VAR9A,0),12,1);
VAR9D:=SMA(IF(VAR9B>0 AND VAR9B>VAR9A,VAR9B,0),12,1);
VAR9E:=VAR9C*100/VAR99;
VAR9F:=VAR9D*100/VAR99;
VARA0:=SMA(ABS(VAR9F-VAR9E)/(VAR9F+VAR9E)*100,12,1);
VARA1:=(VARA0+REF(VARA0,5))/2;
VARA2:=SUM(HIGH-OPEN,12)/SUM(OPEN-LOW,12)*100;
VARA3:=SUM(MAX(0,HIGH-REF(CLOSE,1)),12)/SUM(MAX(0,REF(CLOSE,1)-LOW),12)*100;
VARA4:=AMOUNT/VOL/100;
VARA5:=(3*HIGH+LOW+OPEN+2*CLOSE)/7;
VARA6:=SUM(AMOUNT,5)/VARA4/100;
VARA7:=SUM(AMOUNT,13)/VARA4/100;
VARA8:=SUM(AMOUNT,34)/VARA4/100;
VARA9:=SUM(AMOUNT,209)/VARA4/100;
VARAA:=REF(VOL,1)+REF(VOL,2)+REF(VOL,3)+REF(VOL,4);
VARAB:=VARAA/CAPITAL;
VARAC:=VOL/CAPITAL*VARA5+VARAB*REF(VARA4,1);
VARAD:=DMA(VARA5,VOL/VARA6);
VARAE:=DMA(VARA5,VOL/VARA7);
VARAF:=DMA(VARA5,VOL/VARA8);
VARB0:=DMA(VARA5,VOL/CAPITAL);
VARB1:=MA(HHV(HIGH,488),18);
VARB2:=MA(HHV(HIGH,220),18);
VARB3:=MA(HHV(HIGH,98),18);
VARB4:=MA(LLV(LOW,488),18);
VARB5:=MA(LLV(LOW,220),18);
VARB6:=MA(LLV(LOW,98),18);
VARB7:=MA((VARB4*0.96+VARB5*0.96+VARB6*0.96+VARB1*0.558+VARB2*0.558+VARB3*0.558)/6,18);
VARB8:=MA((VARB4*1.25+VARB5*1.23+VARB6*1.2+VARB1*0.55+VARB2*0.55+VARB3*0.65)/6,18);
VARB9:=MA((VARB4*1.3+VARB5*1.3+VARB6*1.3+VARB1*0.68+VARB2*0.68+VARB3*0.68)/6,18);
VARBA:=MA((VARB7*3+VARB8*2+VARB9)/6*1.738,18);
VARBB:=IF(DATE<=1021231,VARBA,VARBA*DAY);
VARBC:=LOW;
VARBD:=REF(LOW,1);
VARBE:=SMA(ABS(VARBC-VARBD),3,1)/SMA(MAX(VARBC-VARBD,0),3,1)*100;
VARBF:=MA(IF(CLOSE*1.35<=VARBB,VARBE*10,VARBE/10),3);
VARC0:=LLV(LOW,30);
VARC1:=HHV(VARBF,30);
VARC2:=IF(LOW<=VARC0,(VARBF+VARC1*2)/2,0);
WXBM:(MA(VARC2 AND CLOSE
解答:
?探底信号“TROUGHBARS(3,16,1)=0 ”就是未来函数
?
Copyright 2018- www.dyjian.com/ 大宇股票知识网 海口美兰韩哲棚百货商行 版权所有 琼ICP备2023001966号
免责声名:本站所发表的内容仅用于学术交流和学习,内容所带来的一切后果均与本站无关。若您发现本站存在您非授权的原创作品,请第一时间联系本站删除!