广告管理-1170PX*80PX
广告管理-770PX*90PX
当前位置:牛股网 > 牛股公式 >

把同花顺的CPX操盘线改为通达信公式可用的

  • 牛股公式
  • 2020-09-10 14:04
  • 牛股网
广告管理-720PX*80PX

撰写标准:同花顺CPX操盘线源代码:

{CPX操盘线}

bu:=cross(high,SAR(3,1,20));

sel:=cross(SAR(3,1,20),low);

var1:=last(highsar(3,1,20));

drawflagtext(bu,high,'买进');

drawflagtext(sel,low,'售出');

drawtext(bu,LOW,'B'),valign0,align1,coloryellow,linethick2;

drawtext(sel,HIGH,'S'),valign2,align1,colorgreen,linethick2;

STICKLINE(low>SAR(3,1,20) and isdown,high,open,0.5,1),colorred;

STICKLINE(low>SAR(3,1,20) and isdown,close,open,7.5,1),colorred;

STICKLINE(low>SAR(3,1,20) and isdown,close,low,0.5,1),colorred;

STICKLINE(high

STICKLINE(high

STICKLINE(high

drawflagtext(high=ref(high,1),high,'明天提升' forcast(sar(3,1,20),max(var1,2)) '提议关心');

drawflagtext(highref(low,1),low,'再次持仓');

{DPCW大盘仓位}

Ms5:=SMA(MA(C,2),5,3);

Ms13:=SMA(C,13,2);

Ms21:=SMA(C,21,1);

RSV:=(C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100;

a:=SMA(RSV,3,1);

b:=SMA(a,3,1);

DDX:=bigorder(1,2)-bigorder(2,2);

DIFF:=EMA(DDX,6) - EMA(DDX,13);

DIFF2:=EMA(DDX,9) - EMA(DDX,20);

IF(Ms5>REF(Ms5,1)) then

m1:=10;

ELSE IF(Ms5

m1:=-10;

IF(Ms5C) then

m2:=-5;

IF(Ms13>REF(Ms13,1)) then

m3:=5;

ELSE IF(Ms13REF(Ms21,1)) then

m4:=10;

ELSE IF(Ms2190) then

m5:=-10;

ELSE IF(b10) then

m5:=0;

ELSE IF(b0 AND diff2>0) then

m6:=10;

ELSE IF(diff>0 OR diff2>0) then

m6:=0;

ELSE IF(diff<0 AND diff250,0,大盘仓位,9,1),colorF000FF;

STICKLINE(大盘仓位<=50,0,大盘仓位,9,0),colorgreen;

撰写方式 :BU:=CROSS(HIGH,SAR(3,1,20));

SEL:=CROSS(SAR(3,1,20),LOW);

VAR1:=LAST(HIGH<SAR(3,1,20),30,0);

VAR2:=LAST(LOW>SAR(3,1,20),30,0);

DRAWTEXT(BU,HIGH,'买进');

DRAWTEXT(SEL,LOW,'售出');

DRAWTEXT(BU,LOW,'B'),COLORYELLOW,LINETHICK2;

DRAWTEXT(SEL,HIGH,'S'),COLORGREEN,LINETHICK2;

STICKLINE(LOW>SAR(3,1,20) AND O>C,HIGH,OPEN,0,1),COLORRED;

STICKLINE(LOW>SAR(3,1,20) AND O>C,CLOSE,OPEN,3,1),COLORRED;

STICKLINE(LOW>SAR(3,1,20) AND O>C,CLOSE,LOW,0,1),COLORRED;

STICKLINE(HIGH<SAR(3,1,20) AND C>O,HIGH,CLOSE,0,1),COLORCYAN;

STICKLINE(HIGH<SAR(3,1,20) AND C>O,CLOSE,OPEN,3,1),COLORCYAN;

STICKLINE(HIGH<SAR(3,1,20) AND C>O,OPEN,LOW,0,1),COLORCYAN;

广告管理-720PX*80PX

  • 关注微信

相关文章

微信公众号