 | |  |  |
飞狐楚河汉界源码公式:
DRAWGBK(DATE<1090301,COLORRGB(0,100,130),COLORRGB(0,20,20),1);
n:=5;m:=26;
zx:=MA(CLOSE,M);
阻力线:=(zx + N*STD(CLOSE,M)),POINTDOT,LINETHICK2,colorgreen;
拉升力:=(CLOSE-LLV(LOW,25))/(HHV(HIGH,25)-LLV(LOW,47))*1.8*CLOSE;
拉升力A:=SMA(拉升力,9,1);
波峰波谷:=SMA(拉升力A,4,1),colorwhite;
拉升力B:=3*拉升力A-2*波峰波谷;
空方:=3*波峰波谷-1* 拉升力A;
做空:=IF(空方>拉升力B,拉升力B,空方),LINETHICK2,Color00FF00;
短线:=(CLOSE-ma(CLOSE,13))/ma(CLOSE,13)*40,LINETHICK0,COLORYELLOW;
中线:=(CLOSE-MA(CLOSE,4))/MA(CLOSE,4)*40,LINETHICK0,colorwhite;
红柱:=sma(短线,3,1),LINETHICK0,Color0000FF;
蓝柱:=sma(中线,3,1),colorstick,ColorFFFF00;
{红柱}
STICKLINE(红柱<ref(红柱,0.5)and 红柱>0,0,红柱,4,0),COLOR0000AA;
STICKLINE(红柱<ref(红柱,0.5)and 红柱>0,0,红柱,4,0),COLOR0000BB;
STICKLINE(红柱<ref(红柱,0.5)and 红柱>0,0,红柱,4,0),COLOR0000CC;
STICKLINE(红柱<ref(红柱,0.5)and 红柱>0,0,红柱,4,0),COLOR0000DD;
STICKLINE(红柱<ref(红柱,0.5)and 红柱>0,0,红柱,4,0),COLOR0000EE;
STICKLINE(红柱<ref(红柱,1)and 红柱>0,0,红柱,2,0),COLOR0000FF;
STICKLINE(红柱<ref(红柱,1)and 红柱>0,0,红柱,1,0),COLORRED;
STICKLINE(红柱>ref(红柱,1)and 红柱>0,0,红柱,4,0),COLOR0000AA;
STICKLINE(红柱>ref(红柱,1)and 红柱>0,0,红柱,4,0),COLOR0000BB;
STICKLINE(红柱>ref(红柱,1)and 红柱>0,0,红柱,4,0),COLOR0000CC;
STICKLINE(红柱>ref(红柱,1)and 红柱>0,0,红柱,4,0),COLOR0000DD;
STICKLINE(红柱>ref(红柱,1)and 红柱>0,0,红柱,4,0),COLOR0000EE;
STICKLINE(红柱>ref(红柱,1)and 红柱>0,0,红柱,2,0),COLOR0000FF;
STICKLINE(红柱>ref(红柱,1)and 红柱>0,0,红柱,1,0),COLORRED;
STICKLINE(蓝柱<ref(蓝柱,1) and 蓝柱>0,0,蓝柱,4,0),COLOR0000FF;
STICKLINE(蓝柱<ref(蓝柱,1) and 蓝柱>0,0,蓝柱,4,0),COLOR0033FF;
STICKLINE(蓝柱<ref(蓝柱,1) and 蓝柱>0,0,蓝柱,4,0),COLOR0055FF;
STICKLINE(蓝柱<ref(蓝柱,1) and 蓝柱>0,0,蓝柱,4,0),COLOR0077FF;
STICKLINE(蓝柱<ref(蓝柱,1) and 蓝柱>0,0,蓝柱,4,0),COLOR0099FF;
STICKLINE(蓝柱<ref(蓝柱,1) and 蓝柱>0,0,蓝柱,2,0),COLOR00BBFF;
STICKLINE(蓝柱<ref(蓝柱,1) and 蓝柱>0,0,蓝柱,1,0),COLOR00DDFF;
STICKLINE(蓝柱<ref(蓝柱,1) and 蓝柱>0,0,蓝柱,1,0),COLOR00FFFF;
{蓝柱}
STICKLINE(红柱>ref(红柱,0)and 红柱<0,0,红柱,4,0),COLORFF0000;
STICKLINE(红柱>ref(红柱,0)and 红柱<0,0,红柱,4,0),COLORFF3300;
STICKLINE(红柱>ref(红柱,0)and 红柱<0,0,红柱,4,0),COLORFF5500;
STICKLINE(红柱>ref(红柱,0)and 红柱<0,0,红柱,4,0),COLORFF7700;
STICKLINE(红柱>ref(红柱,0)and 红柱<0,0,红柱,4,0),COLORFF9900;
STICKLINE(红柱>ref(红柱,1)and 红柱<0,0,红柱,2,0),COLORFFBB00;
D1:=EMA(((3 * SMA((((CLOSE - LLV(LOW,27)) / (HHV(HIGH,27) - LLV(LOW,27))) * 100),5,1)) - (2 * SMA(SMA((((CLOSE - LLV(LOW,27)) / (HHV(HIGH,27) - LLV(LOW,27))) * 100),5,1),3,1))),5);
D2:=REF(D1,1);
{【多空】:D1,LINETHICK0;
STICKLINE((D1 >= REF(D1,1)),D1,D2,3,0),COLORLIMAGENTA;
STICKLINE((D1 < REF(D1,1)),D1,D2,3,0),COLORLIGREEN;}
楚河:REF((D1-D2)/D2,1)*10,LINETHICK2,COLORff00ff;
AA:=REF(C,1);
汉界:((C/AA)-1)*50,LINETHICK2,colorFFff;
楚河线:1,COLORff00;
汉界线:-0.5,COLOR00ff; |
| |  | |  |
|