飞狐动态月K线指标公式
-
相关简介:飞狐动态月K线指标公式 IF DATATYPE6 then exit; p:=SYSPARAM(1); u:=IF(pBARPOS,0,1); w:=BARSLAST(DAYREF(DAY,1))*u LINETHICK; zr:=w=0; wx:=0*CLOSE; for i=DATACOUNT-1 downto LBOUND(zr) do IF zr[i] then wx[i]:=0; else wx[i]:=wx[i+1]+1; ri:=BACKSET(ISLASTBAR,w+1)-ISL
-
文章来源:股海网作者:股海网发布时间:2014-02-25浏览次数:
飞狐动态月K线指标公式
IF DATATYPE<>6 then exit;
p:=SYSPARAM(1);
u:=IF(p<BARPOS,0,1);
w:=BARSLAST(DAY<REF(DAY,1))*u LINETHICK;
zr:=w=0;
wx:=0*CLOSE;
for i=DATACOUNT-1 downto LBOUND(zr) do
IF zr[i] then
wx[i]:=0;
else
wx[i]:=wx[i+1]+1;
ri:=BACKSET(ISLASTBAR,w+1)-ISLASTBAR;
rw:=REFX(wx,1)+ri;
开:=REF(OPEN,w)LINETHICK;
高:=REFX(HHV(HIGH,w+1),rw)LINETHICK;
低:=REFX(LLV(LOW,w+1),rw)LINETHICK;
收:=REFX(CLOSE,rw)LINETHICK;
f:=收>开 or (收=开 and 收>REF(收,1));
uu:=CROSS(w,rw);
STICKLINE(uu and f and u,高,低,8,0),color8482ff;
STICKLINE(uu and NOT(f) and u,高,低,8,0),colorff9694;
STICKLINE(p=BARPOS and w=0 and f and u,HIGH,LOW,8,0),color8482ff;
STICKLINE(p=BARPOS and w=0 and NOT(f) and u,HIGH,LOW,8,0),colorff9694;
STICKLINE(f and u,收,开,10,0),color8482ff;
STICKLINE(NOT(f) and u,收,开,10,0),colorff9694;
M5:MA(CLOSE,5),COLORWHITE,LINETHICK0;
M20:MA(CLOSE,20),COLORWHITE,LINETHICK0;