缠论一买、三买选股公式(飞狐+悟多公式)

整理文档很辛苦,赏杯茶钱您下走!

免费阅读已结束,点击下载阅读编辑剩下 ...

阅读已结束,您可以下载文档离线阅读编辑

资源描述

缠论一买、三买选股公式(飞狐+悟多公式)公式指标2009-08-1411:42:38阅读5639评论20字号:大中小订阅一买的选股公式初步搞出来的,当然还不完善,不能算是一买的公式,充其量算选出即将盘整背驰的,不过两个中枢下的盘整背驰就是一买了,当然真正是否背驰还要靠人工来判断,它只能初选,不过也省下很多事了,欢迎使用,多提意见。beginifDATAPERIOD=0thenminbi:=fbase.var2#min1;ifDATAPERIOD=1thenminbi:=fbase.var2#min5;ifDATAPERIOD=2thenminbi:=fbase.var2#min30;ifDATAPERIOD=3thenminbi:=fbase.var2#min60;ifDATAPERIOD=4thenminbi:=fbase.var2#day;ifDATAPERIOD=5thenminbi:=fbase.var2#day;ifDATAPERIOD=6thenminbi:=fbase.var2#week;ifDATAPERIOD=7thenminbi:=fbase.var2#month;ifDATAPERIOD=8thenminbi:=fbase.var2#year;var001:=fbase.var2#min30;ifdatatype=3thenvar001:=fbase.var2#min60;ifdatatype=4thenvar001:=fbase.var2#day;var1:=chzhshch@kxian;var2:=chzhshch@bi;{处理笔关系}var3:=chzhshch@tongji(minbi);{同级别分解}zg:=chzhshch@zg(var3);//一定要先调用ZGzd:=chzhshch@zd(var3);zswz:=barslast(zgzd);tj3:=count(abs(var3),barslast(var3=1))=0;tj4:=lref(l,barslast(var2=-1));tj5:=count(var2=1,zswz-1)0;tj6:=ref(h,barslast(var2=1))ref(zd,zswz);tj7:=count(zgzd,barslast(var3=1))0;not(zgzd)&&tj3&&tj7&&tj4&&tj5&&tj6;end;一买是模糊的,不准确的,三买就比较标准了,同样背驰需自行判断,否则不背驰就跌回中枢了:beginifDATAPERIOD=0thenminbi:=fbase.var2#min1;ifDATAPERIOD=1thenminbi:=fbase.var2#min5;ifDATAPERIOD=2thenminbi:=fbase.var2#min30;ifDATAPERIOD=3thenminbi:=fbase.var2#min60;ifDATAPERIOD=4thenminbi:=fbase.var2#day;ifDATAPERIOD=5thenminbi:=fbase.var2#day;ifDATAPERIOD=6thenminbi:=fbase.var2#week;ifDATAPERIOD=7thenminbi:=fbase.var2#month;ifDATAPERIOD=8thenminbi:=fbase.var2#year;var001:=fbase.var2#min30;ifdatatype=3thenvar001:=fbase.var2#min60;ifdatatype=4thenvar001:=fbase.var2#day;var1:=chzhshch@kxian;var2:=chzhshch@bi;{处理笔关系}var3:=chzhshch@tongji(minbi);{同级别分解}zg:=chzhshch@zg(var3);//一定要先调用ZGzd:=chzhshch@zd(var3);var1:=chzhshch@kxian;var2:=chzhshch@bi;var4:=barslast(var0010);tj1:=ref(var001,var2)=-1;//上级别是底var5:=sum(abs(var2),var2);tj2:=var5=1;//第一个回调才算tj3:=count(abs(var3),barslast(var3=-1))=0;zswz:=barslast(zgzd);tj4:=count(zgzd,barslast(var3=-1))0;tj5:=count(var2=1,barslast(var2=-1))=1;tj6:=count(var2=1,zswz-1)=1;tj7:=ref(l,barslast(var2=1))ref(zg,barslast(zgzd));not(zgzd)&&tj3&&tj4&&tj5&&tj6&&tj7;end;MA10:=MA(CLOSE,10);MA5:=MA(CLOSE,5);MA1:=MA5-MA10;MA2:=MA10;MA3:=MA10;DATANUMBER:=DATATYPE;DATANUMBER1:=DATATYPE;DATANUMBER2:=DATATYPE;DATANUMBER3:=DATATYPE;LING:=HIGH;%vbdatanumber=FFL.VarData(datanumber)vbdatanumber1=FFL.VarData(datanumber1)vbdatanumber2=FFL.VarData(datanumber2)vbdata=1vbdata1=0.001vbdata2=1SelectCasevbdatanumberCase0vbdata=0.015vbdata1=0.001vbdata2=0.015Case1vbdata=0.018vbdata1=0.001vbdata2=0.018Case2vbdata=0.037vbdata1=0.001vbdata2=0.037Case3vbdata=0.052vbdata1=0.001vbdata2=0.052Case4vbdata=0.067vbdata1=0.001vbdata2=0.067Case5vbdata=0.13vbdata1=0.001vbdata2=0.13Case6vbdata=0.28vbdata1=0.001vbdata2=0.28Case7vbdata=0.45vbdata1=0.001vbdata2=0.45Case8vbdata=0.73vbdata1=0.001vbdata2=0.73Case9vbdata=1.2vbdata1=0.001vbdata2=1.2Case10vbdata=0.6vbdata1=0.001vbdata2=0.6Case11vbdata=0.1vbdata1=0.001vbdata2=0.1Case12vbdata=0.02vbdata1=0.001vbdata2=0.02Caseelsevbdata=2vbdata1=0.001vbdata2=2EndSelectFFL.VarData(datanumber)=vbdataFFL.VarData(datanumber1)=vbdata1FFL.VarData(datanumber2)=vbdata2vbling=FFL.VarData(ling)vbma=FFL.VarData(ma1)vbma2=FFL.VarData(ma2)vbma3=FFL.VarData(ma3)nlast=UBound(vbma)nvalue=0.0000nvaluefu=0.0000bianhua=2oldbianhua=0form=0tonlastvbma2(m)=0vbma3(m)=0vbling(m)=0nextm=0fori=0tonlastm=m+1'nlast-m'vbma2(i)=0if(vbma(i)0)thenbianhua=1nvalue=nvalue+vbma(i)elsebianhua=2nvaluefu=nvaluefu+vbma(i)endifif(oldbianhua=bianhua)thenelsevbma3(i)=mm=0if(bianhua=1)thenvbma2(i)=nvaluefunvaluefu=0'nvaluefu=0elsevbma2(i)=nvaluenvalue=0'nvalue=0endifendifoldbianhua=bianhuanextFFL.VarData(ma2)=vbma2FFL.VarData(ma3)=vbma3FFL.VarData(ling)=vbling%DRAWNUMBER(REF(MA2,0)0AND0=1,LLV(LOW,5),REF(MA2,0)*1000,0),colorFF00;DRAWNUMBER(REF(MA2,0)0AND0=1,LLV(LOW,5)-DATANUMBER,REF(MA3,0),0),colorFFFF;DRAWNUMBER(REF(MA2,0)0AND0=1,LLV(LOW,5)-DATANUMBER*2,REF(MA2,0)*1000/REF(MA3,0),0),colorFF00;DRAWNUMBER(REF(MA2,0)0AND0=1,HHV(HIGH,5),REF(MA2,0)*1000,0),colorFF;DRAWNUMBER(REF(MA2,0)0AND0=1,HHV(HIGH,5)+DATANUMBER,REF(MA3,0),0),colorFFFF;DRAWNUMBER(REF(MA2,0)0AND0=1,HHV(HIGH,5)+DATANUMBER*2,REF(MA2,0)*1000/REF(MA3,0),0),colorFF;MA1:=MA5-MA10;WEIHE:=LING;WEIPING:=LING;%vbhe=FFL.VarData(weihe)vbping=FFL.VarData(weiping)vbma=FFL.VarData(ma1)nlast=UBound(vbma)nvalue=0.0000nvaluefu=0.0000bianhua=2oldbianhua=0i=0m=nlastif(vbma(nlast)0)thenDoWhile(vbma(m)0)nvalue=vbma(m)+nvaluei=i+1m=m-1if(m0)thenexitdoendifLoopelseDoWhile(vbma(m)0)nvalue=vbma(m)+nvaluei=i+1m=m-1if(m0)thenexitdoendifLoopendifif(i=0)theni=1endifnvaluefu=nvalue/ivbhe(nlast)=nvaluevbping(nlast)=nvaluefuFFL.VarData(weihe)=vbheFFL.VarData(weiping)=vbping%DRAWNUMBER(WEIHE0AND0=1,IF(WEIHE0,HIGH,LOW),WEIHE*1000,0),colorFF;DRAWNUMBER(WEIHE0AND0=1,(IF(WEIHE0,HIGH,LOW))-DATANUMBER*2,WEIPING*1000,0),colorFF00;DRAWNUMBER(WEIPING0AND0=1,(IF(WEIHE0,HIGH,LOW))-DATANUMBER,WEIHE/WEIPING,0),colorFFFF;DIFF:=EMA(CLOSE,12)-EMA(CLOSE,26);DEA:=EMA(DIFF,9);MACD:=2*(DIFF-DEA);MA1:=MACD;MA2:=MACD;MA3:=MACD;MA1

1 / 91
下载文档,编辑使用

©2015-2020 m.777doc.com 三七文档.

备案号:鲁ICP备2024069028号-1 客服联系 QQ:2149211541

×
保存成功