手机版 官方微博
官方微信
扫描关注:理想财富微信公众号
理想论坛App
扫描下载理想论坛App
RSS

请老师帮助把这个同花顺公式改成通达信的

[通达信]
设置
3024 1 无关想想 Lv.1 发表于 · 2020-1-20 09:06 举报 显示全部楼层 复制 正序浏览 |
跳转到指定楼层
MID:=(3*CLOSE+LOW+OPEN+HIGH)/6;
牛线:(20*MID+19*REF(MID,1)+18*REF(MID,2)+17*REF(MID,3)+16*REF(MID,4)+15*REF(MID,5)+14*REF(MID,6)+13*REF(MID,7)+12*REF(MID,8)+11*REF(MID,9)+10*REF(MID,10)+9*REF(MID,11)+8*REF(MID,12)+7*REF(MID,13)+6*REF(MID,14)+5*REF(MID,15)+4*REF(MID,16)+3*REF(MID,17)+2*REF(MID,18)+REF(MID,20))/210,colorred;
马线:MA(牛线,5),colorgreen;
MA5:MA(C,5),colorwhite;
//收盘价高于牛线K线全部用红色,收盘价高于开盘价,K柱用空心柱,否则用实心柱
STICKLINE(C>=牛线 AND C>=0,C,O,9,1),colorred;
STICKLINE(C>=牛线 AND C<=O,C,O,9,0),colorred;
STICKLINE(C>=牛线 AND H>=MAX(C,O),H,MAX(C,O),0,0),colorred;
STICKLINE(C>=牛线 AND L<=MIN(C,O),L,MIN(C,O),0,0),colorred;
//收盘价低于牛线K线全部用浅蓝色,收盘价高于开盘价,K柱用空心柱,否则用实心柱
STICKLINE(C<牛线 AND C<O,C,O,9,0),colorcyan;
STICKLINE(C<牛线 AND C>O,C,O,9,1),colorcyan;
STICKLINE(C<牛线 AND H>=MAX(C,O),H,MAX(C,O),0,0),colorcyan;
STICKLINE(C<牛线 AND L<=MIN(C,O),L,MIN(C,O),0,0),colorcyan;
//买卖点,牛线上穿马线买入,牛线下穿马线卖出
DRAWICON(CROSS(牛线,马线),L*0.99,1);
DRAWICON(CROSS(马线,牛线),H*1.01,2);
买线:=ZIG(3,10);
卖线:=MA(买线,2);
BU:=CROSS(买线,卖线);
SEL:=CROSS(卖线,买线);
DRAWTEXT(bu,L*0.99,'←机构进场'),LINETHICK2,COLOR00FFFF;
DRAWTEXT(sel,H*1.0,'←机构清仓'),linethick1,color00FF00;
DRAWTEXT("X09A.T">0,L*0.99,'B'),linethick1,colorFFffff;
DRAWTEXT("X09A.T1">0,L*0.99,'B'),linethick1,color0000ff;
STICKLINE(买线>=卖线,LOW,HIGH,0.1,0),color0000CC;
STICKLINE(买线>=卖线,CLOSE,OPEN,7,0),color0000CC;
STICKLINE(买线<卖线,CLOSE,OPEN,7,0),colorCCCC00;
STICKLINE(买线<卖线,LOW,HIGH,0.1,0),colorCCCC00;
STICKLINE(CROSS(买线,卖线),OPEN,CLOSE,7,0),color00AAFF;
STICKLINE(CROSS(卖线,买线),OPEN,CLOSE,7,0),color00DD00;
DRAWICON((ZIG(3,5)>REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1)<=REF(ZIG(3,5),2)) AND
(REF(ZIG(3,5),2)<=REF(ZIG(3,5),3)),LOW*0.99,1);
DRAWICON((ZIG(3,5)=REF(ZIG(3,5),2)) AND
(REF(ZIG(3,5),2)>=REF(ZIG(3,5),3)),H,2);
VARC:=(ZIG(3,5)>REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1)<=REF(ZIG(3,5),2)) AND
(REF(ZIG(3,5),2)<=REF(ZIG(3,5),3));
VARD:=(ZIG(3,5)=REF(ZIG(3,5),2)) AND
(REF(ZIG(3,5),2)>=REF(ZIG(3,5),3));
DRAWTEXT((VARC=1),L,'←买'),COLOR0000FF;
DRAWTEXT((VARD=1),H,'←卖'),color00FF00;
V10:=PEAKBARS(3,15,1)<10;
V12:=IF(V10=1,50,0);
头部:= IF(V12=50,100,0);
DRAWTEXT(IF(头部>REF(头部,1),H,0),H*1.02,'←拉升减仓 '),colorwhite,LINETHICK1;
V9:=TROUGHBARS(3,15,1)<10;
V11:=IF(V9=1,50,0);
DRAWTEXT(IF( IF(V11=50,50,0)>REF(IF(V11=50,50,0),1),L,0),L*0.96,'↖抄底 '),colormagenta;
VARE:=MA(100*(CLOSE-LLV(CLOSE,34))/(HHV(HIGH,34)-LLV(LOW,34)),5)-20;
VARF:=100-3*SMA((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1)+2*SMA(SMA
((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1);
VAR10:=100-3*SMA((OPEN-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1)+2*SMA(SMA
((OPEN-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1);
VAR11:=VARF<REF(VAR10,1) AND VOL>REF(VOL,1) AND CLOSE>REF(CLOSE,1);
DRAWTEXT(VAR11 AND COUNT(VAR11,30)=1,L*0.99,'←短线资金进'),LINETHICK1,colorlimagenta;
Var12:=(HIGH+LOW+CLOSE)/3;
Var13:=(Var12-MA(Var12,14))/(0.015*AVEDEV(Var12,14));
Var14:=(Var12-MA(Var12,70))/(0.015*AVEDEV(Var12,70));
Var15:=IF(Var13>=150 AND Var13<200 AND Var14>=150 AND Var14<200,10,0);
Var16:=IF(Var13<=-150 AND Var13>-200 AND Var14<=-150 AND Var14>-200,-10,Var15);
Var17:=(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*100;
Var18:=100-ABS(Var17);
Var19:=IF(Var18<90,Var18,100);
Var1A:=IF(VarE>0,VarE,0);
Var1B:=IF(Var14>=200 AND Var13>=150,15,IF(Var14<=-200 AND Var13<=-150,-15,Var16))+60;
Var1C:=Var1A>48 AND Var1B>60 AND Var19<100;
DRAWTEXT(Var1C AND COUNT(Var1C,30)=1,H*1,'←短线资金出'),linethick1,colorliblue;
VARE:=REF(LOW,1)*0.9;
VARF:=LOW*0.9;
VAR10:=(VARF*VOL+VARE*(CAPITAL-VOL))/CAPITAL;
VAR11:=EMA(VAR10,30);
VAR12:=CLOSE-REF(CLOSE,1);
VAR13:=MAX(VAR12,0);
VAR14:=ABS(VAR12);
VAR15:=SMA(VAR13,7,1)/SMA(VAR14,7,1)*100;
VAR16:=SMA(VAR13,13,1)/SMA(VAR14,13,1)*100;
VAR17:=BARSCOUNT(CLOSE);
VAR18:=SMA(MAX(VAR12,0),6,1)/SMA(ABS(VAR12),6,1)*100;
VAR19:=(-200)*(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60))+100;
VAR1A:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;
VAR1B:=SMA((SMA(VAR1A,4,1)-50)*2,3,1);
VAR1C:=(INDEXC-LLV(INDEXL,14))/(HHV(INDEXH,14)-LLV(INDEXL,14))*100;
VAR1D:=SMA(VAR1C,4,1);
VAR1E:=SMA(VAR1D,3,1);
VAR1F:=(HHV(HIGH,30)-CLOSE)/CLOSE*100;
VAR20:=VAR18<=25 AND VAR19<-95 AND VAR1F>20 AND VAR1B<-30 AND VAR1E<30 AND VAR11-CLOSE>=-0.25 AND VAR15<22 AND VAR16<28 AND VAR17>50;
VAR21:=(HIGH+LOW+CLOSE)/3;
VAR22:=(VAR21-MA(VAR21,14))/(0.015*AVEDEV(VAR21,14));
VAR23:=(VAR21-MA(VAR21,70))/(0.015*AVEDEV(VAR21,70));
VAR24:=IF(VAR22>=150 AND VAR22<200 AND VAR23>=150 AND VAR23<200,10,0);
VAR25:=IF(VAR22<=-150 AND VAR22>-200 AND VAR23<=-150 AND VAR23>-200,-10,VAR24);
DRAWTEXT(VAR20 AND COUNT(VAR20,1)=1,H*0.99,'↖基金建仓!') , colormagenta;
DRAWTEXT(VAR24 AND COUNT(VAR24,1)=1,L*1.1,'↙基金清仓!') , color00FF00;
乖离率:(C-牛线)/C*100,NODRAW,colorgreen;


相关股票

休闲者68
Lv.6
发表于 2020-1-20 19:26 复制 查看全部楼层
MID:=(3*CLOSE+LOW+OPEN+HIGH)/6;
牛线:(20*MID+19*REF(MID,1)+18*REF(MID,2)+17*REF(MID,3)+16*REF(MID,4)+15*REF(MID,5)+14*REF(MID,6)+13*REF(MID,7)+12*REF(MID,8)+11*REF(MID,9)+10*REF(MID,10)+9*REF(MID,11)+8*REF(MID,12)+7*REF(MID,13)+6*REF(MID,14)+5*REF(MID,15)+4*REF(MID,16)+3*REF(MID,17)+2*REF(MID,18)+REF(MID,20))/210,COLORRED;
马线:MA(牛线,5),COLORGREEN;
MA5:MA(C,5),COLORWHITE;
{收盘价高于牛线K线全部用红色,收盘价高于开盘价,K柱用空心柱,否则用实心柱}
STICKLINE(C>=牛线 AND C>=0,C,O,2,1),COLORRED;
STICKLINE(C>=牛线 AND C<=O,C,O,2,0),COLORRED;
STICKLINE(C>=牛线 AND H>=MAX(C,O),H,MAX(C,O),0,0),COLORRED;
STICKLINE(C>=牛线 AND L<=MIN(C,O),L,MIN(C,O),0,0),COLORRED;
{收盘价低于牛线K线全部用浅蓝色,收盘价高于开盘价,K柱用空心柱,否则用实心柱}
STICKLINE(C<牛线 AND C<O,C,O,2,0),COLORCYAN;
STICKLINE(C<牛线 AND C>O,C,O,2,1),COLORCYAN;
STICKLINE(C<牛线 AND H>=MAX(C,O),H,MAX(C,O),0,0),COLORCYAN;
STICKLINE(C<牛线 AND L<=MIN(C,O),L,MIN(C,O),0,0),COLORCYAN;
{买卖点,牛线上穿马线买入,牛线下穿马线卖出}
DRAWICON(CROSS(牛线,马线),L*0.99,1);
DRAWICON(CROSS(马线,牛线),H*1.01,2);
买线:=ZIG(3,10);
卖线:=MA(买线,2);
BU:=CROSS(买线,卖线);
SEL:=CROSS(卖线,买线);
DRAWTEXT(BU,L*0.99,'←机构进场'),LINETHICK2,COLOR00FFFF;
DRAWTEXT(SEL,H*1.0,'←机构清仓'),LINETHICK1,COLOR00FF00;
DRAWTEXT('X09A.T'>0,L*0.99,'B'),LINETHICK1,COLORFFFFFF;
DRAWTEXT('X09A.T1'>0,L*0.99,'B'),LINETHICK1,COLOR0000FF;
STICKLINE(买线>=卖线,LOW,HIGH,0.1,0),COLOR0000CC;
STICKLINE(买线>=卖线,CLOSE,OPEN,2,0),COLOR0000CC;
STICKLINE(买线<卖线,CLOSE,OPEN,2,0),COLORCCCC00;
STICKLINE(买线<卖线,LOW,HIGH,0.1,0),COLORCCCC00;
STICKLINE(CROSS(买线,卖线),OPEN,CLOSE,2,0),COLOR00AAFF;
STICKLINE(CROSS(卖线,买线),OPEN,CLOSE,2,0),COLOR00DD00;
DRAWICON((ZIG(3,5)>REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1)<=REF(ZIG(3,5),2)) AND
(REF(ZIG(3,5),2)<=REF(ZIG(3,5),3)),LOW*0.99,1);
DRAWICON((ZIG(3,5)=REF(ZIG(3,5),2)) AND
(REF(ZIG(3,5),2)>=REF(ZIG(3,5),3)),H,2);
VARC:=(ZIG(3,5)>REF(ZIG(3,5),1)) AND (REF(ZIG(3,5),1)<=REF(ZIG(3,5),2)) AND
(REF(ZIG(3,5),2)<=REF(ZIG(3,5),3));
VARD:=(ZIG(3,5)=REF(ZIG(3,5),2)) AND
(REF(ZIG(3,5),2)>=REF(ZIG(3,5),3));
DRAWTEXT((VARC=1),L,'←买'),COLOR0000FF;
DRAWTEXT((VARD=1),H,'←卖'),COLOR00FF00;
V10:=PEAKBARS(3,15,1)<10;
V12:=IF(V10=1,50,0);
头部:= IF(V12=50,100,0);
DRAWTEXT(IF(头部>REF(头部,1),H,0),H*1.02,'←拉升减仓 '),COLORWHITE,LINETHICK1;
V9:=TROUGHBARS(3,15,1)<10;
V11:=IF(V9=1,50,0);
DRAWTEXT(IF( IF(V11=50,50,0)>REF(IF(V11=50,50,0),1),L,0),L*0.96,'↖抄底 '),COLORMAGENTA;
VARE:=MA(100*(CLOSE-LLV(CLOSE,34))/(HHV(HIGH,34)-LLV(LOW,34)),5)-20;
VARF:=100-3*SMA((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1)+2*SMA(SMA
((CLOSE-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1);
VAR10:=100-3*SMA((OPEN-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1)+2*SMA(SMA
((OPEN-LLV(LOW,75))/(HHV(HIGH,75)-LLV(LOW,75))*100,20,1),15,1);
VAR11:=VARF<REF(VAR10,1) AND VOL>REF(VOL,1) AND CLOSE>REF(CLOSE,1);
DRAWTEXT(VAR11 AND COUNT(VAR11,30)=1,L*0.99,'←短线资金进'),LINETHICK1,COLORLIMAGENTA;
VAR12:=(HIGH+LOW+CLOSE)/3;
VAR13:=(VAR12-MA(VAR12,14))/(0.015*AVEDEV(VAR12,14));
VAR14:=(VAR12-MA(VAR12,70))/(0.015*AVEDEV(VAR12,70));
VAR15:=IF(VAR13>=150 AND VAR13<200 AND VAR14>=150 AND VAR14<200,10,0);
VAR16:=IF(VAR13<=-150 AND VAR13>-200 AND VAR14<=-150 AND VAR14>-200,-10,VAR15);
VAR17:=(CLOSE-MA(CLOSE,13))/MA(CLOSE,13)*100;
VAR18:=100-ABS(VAR17);
VAR19:=IF(VAR18<90,VAR18,100);
VAR1A:=IF(VARE>0,VARE,0);
VAR1B:=IF(VAR14>=200 AND VAR13>=150,15,IF(VAR14<=-200 AND VAR13<=-150,-15,VAR16))+60;
VAR1C:=VAR1A>48 AND VAR1B>60 AND VAR19<100;
DRAWTEXT(VAR1C AND COUNT(VAR1C,30)=1,H*1,'←短线资金出'),LINETHICK1,COLORLIBLUE;
VAREE:=REF(LOW,1)*0.9;
VARFF:=LOW*0.9;
VAR100:=(VARFF*VOL+VAREE*(CAPITAL-VOL))/CAPITAL;
VAR111:=EMA(VAR10,30);
VAR122:=CLOSE-REF(CLOSE,1);
VAR133:=MAX(VAR122,0);
VAR144:=ABS(VAR122);
VAR155:=SMA(VAR133,7,1)/SMA(VAR144,7,1)*100;
VAR166:=SMA(VAR133,13,1)/SMA(VAR144,13,1)*100;
VAR177:=BARSCOUNT(CLOSE);
VAR188:=SMA(MAX(VAR122,0),6,1)/SMA(ABS(VAR122),6,1)*100;
VAR199:=(-200)*(HHV(HIGH,60)-CLOSE)/(HHV(HIGH,60)-LLV(LOW,60))+100;
VAR1AA:=(CLOSE-LLV(LOW,15))/(HHV(HIGH,15)-LLV(LOW,15))*100;
VAR1BB:=SMA((SMA(VAR1AA,4,1)-50)*2,3,1);
VAR1CC:=(INDEXC-LLV(INDEXL,14))/(HHV(INDEXH,14)-LLV(INDEXL,14))*100;
VAR1DD:=SMA(VAR1CC,4,1);
VAR1E:=SMA(VAR1DD,3,1);
VAR1F:=(HHV(HIGH,30)-CLOSE)/CLOSE*100;
VAR20:=VAR18<=25 AND VAR19<-95 AND VAR1F>20 AND VAR1B<-30 AND VAR1E<30 AND VAR11-CLOSE>=-0.25 AND VAR15<22 AND VAR16<28 AND VAR17>50;
VAR21:=(HIGH+LOW+CLOSE)/3;
VAR22:=(VAR21-MA(VAR21,14))/(0.015*AVEDEV(VAR21,14));
VAR23:=(VAR21-MA(VAR21,70))/(0.015*AVEDEV(VAR21,70));
VAR24:=IF(VAR22>=150 AND VAR22<200 AND VAR23>=150 AND VAR23<200,10,0);
VAR25:=IF(VAR22<=-150 AND VAR22>-200 AND VAR23<=-150 AND VAR23>-200,-10,VAR24);
DRAWTEXT(VAR20 AND COUNT(VAR20,1)=1,H*0.99,'↖基金建仓!') , COLORMAGENTA;
DRAWTEXT(VAR24 AND COUNT(VAR24,1)=1,L*1.1,'↙基金清仓!') , COLOR00FF00;
乖离率:(C-牛线)/C*100,NODRAW,COLORGREEN;
您需要登录后才可以回帖 免费注册登录

本版积分规则

回顶部 到页底
快速回复 返回顶部 返回列表