飞狐公式下载 飞狐十日箱体主图公式源码
2016-08-22 11:15 股票知识 zhishi.southmoney.com
飞狐公式下载 飞狐十日箱体主图公式源码 南方财富网小编为您提供
ST:=(CLOSE/OPEN+1)*100;
ZF:=(C/REF(C,1)+1)*100;
SX1:=ST>3 AND ST=HHV(ST,5);
SX2:=ZF>3 AND ZF=HHV(ZF,5);
SX3:=ZF>=9 AND CLOSE=HIGH;
S:=IF(SX1 OR SX2 OR SX3,1,0),COLOR0000FF;
DYSJ:=WEEKDAY;
监测:=IF(DYSJ<=13 AND COUNT(C>REF(L,DYSJ),DYSJ)>=DYSJ+1,DYSJ,0),COLOR00FFFF;
关注:=IF(DYSJ>=5 AND COUNT(H>REF(H,DYSJ),5)>=5,REF(H,DYSJ),REF(H,DYSJ)),COLOR00FFFF;
监测②:=IF(关注=REF(L,DYSJ),REF(L,DYSJ),REF(L,DYSJ)),COLORFFFFFF;
STICKLINE(监测,监测②,监测②,3,0),COLOR00FFFF;
BF1:=LOW<关注*1.01 AND COUNT(LOW<关注*1.01,监测)=1;
BF2:=LOW<关注 AND COUNT(LOW<关注,监测)=1;
BF:=IF(BF1 OR BF2,1,0),COLOR00FF00;
{以下设置主图显示方式}
支撑:STICKLINE(监测,关注,关注,6,0),COLORFF00FF;
STICKLINE(C>0,关注,关注,5,-1),COLORFFFFFF;
HHJSJDA:=(2.97*CLOSE+OPEN+LOW+HIGH)/6;
HHJSJDB:=(20*HHJSJDA+19*REF(HHJSJDA,1)+18*REF(HHJSJDA,2)+17*REF(HHJSJDA,3)+16*REF(HHJSJDA,4)+15*REF(HHJSJDA,5)+14*REF(HHJSJDA,6)
+13*REF(HHJSJDA,7)+12*REF(HHJSJDA,8)+11*REF(HHJSJDA,9)+10*REF(HHJSJDA,10)+9*REF(HHJSJDA,11)+8*REF(HHJSJDA,12)
+7*REF(HHJSJDA,13)+6*REF(HHJSJDA,14)+5*REF(HHJSJDA,15)+4*REF(HHJSJDA,16)+3*REF(HHJSJDA,17)+2*REF(HHJSJDA,18)+
REF(HHJSJDA,20))/210,COLORYELLOW;
HHJSJDC:=MA(HHJSJDB,5),COLORWHITE;
//DRAWBAND(MA(HHJSJDB,1),RGB(96,50,96),MA(HHJSJDB,5),RGB(15,96,96));
FILLRGN(MA(HHJSJDB,1)>MA(HHJSJDB,5),MA(HHJSJDB,1)+0.05,MA(HHJSJDB,5)),colorgreen;
FILLRGN(MA(HHJSJDB,1)<MA(HHJSJDB,5),MA(HHJSJDB,1)-0.05,MA(HHJSJDB,5)),colormagenta;
【箱顶】:PEAK(HIGH,10,1)*0.98,colorred,linethick2;
【箱底】:TROUGH(LOW,10,1)*1.02,colorcyan,linethick2;
YY1:=C>MA(C,11) AND OPEN<MA(C,11);
YY3:=C>MA(C,33) AND OPEN<MA(C,33);
YY5:=C>MA(C,55) AND OPEN<MA(C,55);
DRAWTEXT(YY1 AND YY5 AND YY3,LOW-0.1,'一\n阳\n三\n线'),COLORRED;
A3:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
A4:=SMA(A3,3,1);
A5:=SMA(A4,3,1);
A6:=3*A4-2*A5;
A7:=C-REF(C,1);
A8:=100*EMA(EMA(A7,6),6)/EMA(EMA(ABS(A7),6),6);
买:=LLV(A8,2)=LLV(A8,7) AND COUNT(A8<0,2) AND CROSS(A8,MA(A8,2));
STICKLINE(买,OPEN,CLOSE,2,0),COLORYELLOW;
{XU:PEAK(C,IF(PERIOD<5,5,10),1)*0.999,COLORFFCC99,LINETHICK1;
XD:TROUGH(C,IF(PERIOD<5,5,10),1)*0.998,COLORFF99CC,LINETHICK1;
XH:=(XU-XD)/XD*100;
XDU:=IF(EMA(EMA(EMA(C,2),2),2)>REF(EMA(EMA(EMA(C,2),2),2),1),XD,XU);
XR:=(C-XDU)/XDU*100;
XTB:=XD!=REF(XD,2) && XD=REF(XD,1);
XTS:=XU!=REF(XU,2) && XU=REF(XU,1);
DRAWICON(XTB,MIN(XD,L)*0.991,1);
DRAWTEXT(XTB,MIN(XD,L)*0.995,'升点!满仓'),COLOR0000DD;
DRAWICON(XTS,MAX(XU,H)*1.006,2);
DRAWTEXT(XTS,MIN(XU,H)*1.008,'跌点!清仓')COLOR00DD00;
上升段:DRAWLINE(XTB,MIN(LLV(L,1),XD),XTS,MAX(HHV(H,1),XU),0)
COLOR000099,LINETHICK2;{XTBL}
下跌段:DRAWLINE(XTS,MAX(HHV(H,1),XU),XTB,MIN(LLV(L,1),XD),0)
COLOR009900,LINETHICK2;{XTSL};}
VAR2X:=TROUGHBARS(3,15,1)<10;
VAR3X:=PEAKBARS(3,15,1)<10;
VAR4X:=IF(VAR2X=1,50,0);
VAR5X:=IF(VAR3X=1,50,0);
底部:=IF(VAR4X=50,10,0);
多头能量:=0,COLORWHITE,LINETHICK2;
买入:=IF(底部=10 AND REF(底部,1)=10 AND REF(底部,2)=0,50,0),COLOR0000CC,LINETHICK2;
{买入延迟线:底部,LINETHICK1 ,COLOR00CCFF;}
STICKLINE(买入=50,H*1.1,L*0.97,4,0);
DRAWTEXT(买入=50,L*0.965,'神\n踹'),COLORGREEN;
操:=MA(c,5);
分界:HHV(操,13),LINETHICK2,COLORffb9cc;
BIAS1:=MA((CLOSE-MA(CLOSE,13))/MA(CLOSE,13),3)*100,COLORWHITE;
BIAS3:=MA((CLOSE-MA(CLOSE,27))/MA(CLOSE,27),3)*100,COLORFF00FF,LINETHICK2;
操作区:=IF(BIAS3<0,BIAS3,0),COLORRED,LINETHICK3;
观望区:=IF(BIAS3>0,BIAS3,0),COLORGREEN,LINETHICK3;
VAR2K:=TROUGHBARS(3,15,1)<10;
VAR3K:=PEAKBARS(3,15,1)<10;
VAR4K:=IF(VAR2K=1,50,0);
VAR5K:=IF(VAR3K=1,50,0);
TJ1K:=观望区<REF(观望区,1) OR 观望区-REF(观望区,1)<REF(观望区,1)-REF(观望区,2);
TJ2K:=操作区>REF(操作区,1);
顶:=IF(TJ1K AND VAR5K=50,15,0),STICK,LINETHICK1,COLORGREEN;
底:=IF(TJ2K AND VAR4K=50,10,0),STICK,LINETHICK1,COLORRED;
DRAWICON(TJ1K AND VAR5K=50,HHV(H,10)+0.1,5);
DRAWICON(TJ2K AND VAR4K=50,LLV(L,10)-0.06,4);
STICKLINE(TJ1K AND VAR5K=50,HHV(H,10),HHV(H,10)-0.1,3,1),COLORGREEN;
STICKLINE(TJ2K AND VAR4K=50,LLV(L,10),LLV(L,10)+0.1,3,1),COLORRED;
Var1:=EMA(C,3);
Var2:=EMA(C,5);
Var3:=EMA(C,10);
Var4:=EMA(C,20);
Var5:=EMA(C,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(Var7<1*REF(Var7,1),h,l,0.5,0),COLORBLUE;
STICKLINE(Var7<1*REF(Var7,1),o,c,8,0),COLORBLUE;
STICKLINE(Var7>1*REF(Var7,1),h,l,0.5,0),COLORRED;
STICKLINE(Var7>1*REF(Var7,1),o,c,8,0),COLORRED;
STICKLINE(Var7<1*REF(Var7,1) AND Var9>1*REF(Var9,1),h,l,0.5,0),COLORGREEN;
STICKLINE(Var7<1*REF(Var7,1) AND Var9>1*REF(Var9,1),o,c,8,0),COLORGREEN;
买进价:=((c-ref(ma(c,6),1))/6+ma(c,6))*1.004;
买进条件:=cross(c,买进价) and 买进价>ref(买进价,1);
STICKLINE(买进条件,h,l,0.5,0),colorwhite,linethick2;
STICKLINE(买进条件,o,c,8,0),colorwhite,linethick2;
加码价:=((c-ref(ma(c,18),1))/18+ma(c,18))*1.004;
加码条件:=cross(c,加码价) and 加码价>ref(加码价,1);
STICKLINE(加码条件,h,l,0.5,0),coloryellow,linethick2;
STICKLINE(加码条件,o,c,8,0),coloryellow,linethick2;
ZF:=(C/REF(C,1)+1)*100;
SX1:=ST>3 AND ST=HHV(ST,5);
SX2:=ZF>3 AND ZF=HHV(ZF,5);
SX3:=ZF>=9 AND CLOSE=HIGH;
S:=IF(SX1 OR SX2 OR SX3,1,0),COLOR0000FF;
DYSJ:=WEEKDAY;
监测:=IF(DYSJ<=13 AND COUNT(C>REF(L,DYSJ),DYSJ)>=DYSJ+1,DYSJ,0),COLOR00FFFF;
关注:=IF(DYSJ>=5 AND COUNT(H>REF(H,DYSJ),5)>=5,REF(H,DYSJ),REF(H,DYSJ)),COLOR00FFFF;
监测②:=IF(关注=REF(L,DYSJ),REF(L,DYSJ),REF(L,DYSJ)),COLORFFFFFF;
STICKLINE(监测,监测②,监测②,3,0),COLOR00FFFF;
BF1:=LOW<关注*1.01 AND COUNT(LOW<关注*1.01,监测)=1;
BF2:=LOW<关注 AND COUNT(LOW<关注,监测)=1;
BF:=IF(BF1 OR BF2,1,0),COLOR00FF00;
{以下设置主图显示方式}
支撑:STICKLINE(监测,关注,关注,6,0),COLORFF00FF;
STICKLINE(C>0,关注,关注,5,-1),COLORFFFFFF;
HHJSJDA:=(2.97*CLOSE+OPEN+LOW+HIGH)/6;
HHJSJDB:=(20*HHJSJDA+19*REF(HHJSJDA,1)+18*REF(HHJSJDA,2)+17*REF(HHJSJDA,3)+16*REF(HHJSJDA,4)+15*REF(HHJSJDA,5)+14*REF(HHJSJDA,6)
+13*REF(HHJSJDA,7)+12*REF(HHJSJDA,8)+11*REF(HHJSJDA,9)+10*REF(HHJSJDA,10)+9*REF(HHJSJDA,11)+8*REF(HHJSJDA,12)
+7*REF(HHJSJDA,13)+6*REF(HHJSJDA,14)+5*REF(HHJSJDA,15)+4*REF(HHJSJDA,16)+3*REF(HHJSJDA,17)+2*REF(HHJSJDA,18)+
REF(HHJSJDA,20))/210,COLORYELLOW;
HHJSJDC:=MA(HHJSJDB,5),COLORWHITE;
//DRAWBAND(MA(HHJSJDB,1),RGB(96,50,96),MA(HHJSJDB,5),RGB(15,96,96));
FILLRGN(MA(HHJSJDB,1)>MA(HHJSJDB,5),MA(HHJSJDB,1)+0.05,MA(HHJSJDB,5)),colorgreen;
FILLRGN(MA(HHJSJDB,1)<MA(HHJSJDB,5),MA(HHJSJDB,1)-0.05,MA(HHJSJDB,5)),colormagenta;
【箱顶】:PEAK(HIGH,10,1)*0.98,colorred,linethick2;
【箱底】:TROUGH(LOW,10,1)*1.02,colorcyan,linethick2;
YY1:=C>MA(C,11) AND OPEN<MA(C,11);
YY3:=C>MA(C,33) AND OPEN<MA(C,33);
YY5:=C>MA(C,55) AND OPEN<MA(C,55);
DRAWTEXT(YY1 AND YY5 AND YY3,LOW-0.1,'一\n阳\n三\n线'),COLORRED;
A3:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;
A4:=SMA(A3,3,1);
A5:=SMA(A4,3,1);
A6:=3*A4-2*A5;
A7:=C-REF(C,1);
A8:=100*EMA(EMA(A7,6),6)/EMA(EMA(ABS(A7),6),6);
买:=LLV(A8,2)=LLV(A8,7) AND COUNT(A8<0,2) AND CROSS(A8,MA(A8,2));
STICKLINE(买,OPEN,CLOSE,2,0),COLORYELLOW;
{XU:PEAK(C,IF(PERIOD<5,5,10),1)*0.999,COLORFFCC99,LINETHICK1;
XD:TROUGH(C,IF(PERIOD<5,5,10),1)*0.998,COLORFF99CC,LINETHICK1;
XH:=(XU-XD)/XD*100;
XDU:=IF(EMA(EMA(EMA(C,2),2),2)>REF(EMA(EMA(EMA(C,2),2),2),1),XD,XU);
XR:=(C-XDU)/XDU*100;
XTB:=XD!=REF(XD,2) && XD=REF(XD,1);
XTS:=XU!=REF(XU,2) && XU=REF(XU,1);
DRAWICON(XTB,MIN(XD,L)*0.991,1);
DRAWTEXT(XTB,MIN(XD,L)*0.995,'升点!满仓'),COLOR0000DD;
DRAWICON(XTS,MAX(XU,H)*1.006,2);
DRAWTEXT(XTS,MIN(XU,H)*1.008,'跌点!清仓')COLOR00DD00;
上升段:DRAWLINE(XTB,MIN(LLV(L,1),XD),XTS,MAX(HHV(H,1),XU),0)
COLOR000099,LINETHICK2;{XTBL}
下跌段:DRAWLINE(XTS,MAX(HHV(H,1),XU),XTB,MIN(LLV(L,1),XD),0)
COLOR009900,LINETHICK2;{XTSL};}
VAR2X:=TROUGHBARS(3,15,1)<10;
VAR3X:=PEAKBARS(3,15,1)<10;
VAR4X:=IF(VAR2X=1,50,0);
VAR5X:=IF(VAR3X=1,50,0);
底部:=IF(VAR4X=50,10,0);
多头能量:=0,COLORWHITE,LINETHICK2;
买入:=IF(底部=10 AND REF(底部,1)=10 AND REF(底部,2)=0,50,0),COLOR0000CC,LINETHICK2;
{买入延迟线:底部,LINETHICK1 ,COLOR00CCFF;}
STICKLINE(买入=50,H*1.1,L*0.97,4,0);
DRAWTEXT(买入=50,L*0.965,'神\n踹'),COLORGREEN;
操:=MA(c,5);
分界:HHV(操,13),LINETHICK2,COLORffb9cc;
BIAS1:=MA((CLOSE-MA(CLOSE,13))/MA(CLOSE,13),3)*100,COLORWHITE;
BIAS3:=MA((CLOSE-MA(CLOSE,27))/MA(CLOSE,27),3)*100,COLORFF00FF,LINETHICK2;
操作区:=IF(BIAS3<0,BIAS3,0),COLORRED,LINETHICK3;
观望区:=IF(BIAS3>0,BIAS3,0),COLORGREEN,LINETHICK3;
VAR2K:=TROUGHBARS(3,15,1)<10;
VAR3K:=PEAKBARS(3,15,1)<10;
VAR4K:=IF(VAR2K=1,50,0);
VAR5K:=IF(VAR3K=1,50,0);
TJ1K:=观望区<REF(观望区,1) OR 观望区-REF(观望区,1)<REF(观望区,1)-REF(观望区,2);
TJ2K:=操作区>REF(操作区,1);
顶:=IF(TJ1K AND VAR5K=50,15,0),STICK,LINETHICK1,COLORGREEN;
底:=IF(TJ2K AND VAR4K=50,10,0),STICK,LINETHICK1,COLORRED;
DRAWICON(TJ1K AND VAR5K=50,HHV(H,10)+0.1,5);
DRAWICON(TJ2K AND VAR4K=50,LLV(L,10)-0.06,4);
STICKLINE(TJ1K AND VAR5K=50,HHV(H,10),HHV(H,10)-0.1,3,1),COLORGREEN;
STICKLINE(TJ2K AND VAR4K=50,LLV(L,10),LLV(L,10)+0.1,3,1),COLORRED;
Var1:=EMA(C,3);
Var2:=EMA(C,5);
Var3:=EMA(C,10);
Var4:=EMA(C,20);
Var5:=EMA(C,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(Var7<1*REF(Var7,1),h,l,0.5,0),COLORBLUE;
STICKLINE(Var7<1*REF(Var7,1),o,c,8,0),COLORBLUE;
STICKLINE(Var7>1*REF(Var7,1),h,l,0.5,0),COLORRED;
STICKLINE(Var7>1*REF(Var7,1),o,c,8,0),COLORRED;
STICKLINE(Var7<1*REF(Var7,1) AND Var9>1*REF(Var9,1),h,l,0.5,0),COLORGREEN;
STICKLINE(Var7<1*REF(Var7,1) AND Var9>1*REF(Var9,1),o,c,8,0),COLORGREEN;
买进价:=((c-ref(ma(c,6),1))/6+ma(c,6))*1.004;
买进条件:=cross(c,买进价) and 买进价>ref(买进价,1);
STICKLINE(买进条件,h,l,0.5,0),colorwhite,linethick2;
STICKLINE(买进条件,o,c,8,0),colorwhite,linethick2;
加码价:=((c-ref(ma(c,18),1))/18+ma(c,18))*1.004;
加码条件:=cross(c,加码价) and 加码价>ref(加码价,1);
STICKLINE(加码条件,h,l,0.5,0),coloryellow,linethick2;
STICKLINE(加码条件,o,c,8,0),coloryellow,linethick2;
更多股票公式相关资讯请关注南方财富网
股票知识网声明:资讯来源于合作媒体及机构,属作者个人观点,仅供投资者参考,并不构成投资建议。投资者据此操作,风险自担。