宝塔线指标公式源码最新

| 淑娟

对于炒股的人来说,不同指标的应用肯定是要了解的,技术指标的分析中,这宝塔线指标就是其中之一了,今天小编整理了宝塔线指标公式源码最新供大家参考,一起来看看吧!

宝塔线指标公式源码最新

宝塔线指标公式源码大全最新

MA5:MA(C,5),COLORYELLOW;

MA10:MA(C,10),COLORFF00FF;

MA15:MA(C,15),COLOR00FF00;

MA30:MA(C,30),COLORFFCCCC;

B1:=REF(C,1);B2:=REF(C,2);

SS:=IF(C>REF(C,1) AND REF(C,1)>=REF(C,2),1,IF(C<ref(c,1) ref(c,1)REF(C,2) AND REF(C,2)>REF(C,1),2,IF(C<ref(c,2) and="" p="" ref(c,2)<ref(c,1),-2,0))));

SM:=IF(REF(SS,1)!=0,REF(SS,1),IF(REF(SS,2)!=0,REF(SS,2),IF(REF(SS,3)!=0,REF(SS,3),IF(REF(SS,5)!=0,REF(SS,5),IF(REF(SS,6)!=0,REF(SS,6),IF(REF(SS,7)!=0,REF(SS,7),0))))));

STICKLINE(SS=1 OR SM>=1 AND SS=0,B1,C,3,0),COLORRED;

STICKLINE(SS=-1 OR SM<=-1 AND SS=0,B1,C,3,0),COLORFFCC66;

STICKLINE(SS=2,B2,C,3,0),COLORRED;

STICKLINE(SS=-2,B2,C,3,0),COLORFFCC66;

STICKLINE((SS=-1 OR SS=-2) AND SM>0,B2,B1,3,0),COLORRED;

STICKLINE((SS=1 OR SS=2) AND SM<0,B2,B1,3,0),COLORFFCC66;

AA:=CLOSE>REF(CLOSE,1) AND REF(CLOSE,1)>REF(CLOSE,2) AND REF(CLOSE,1)<ref(close,3) and="" ref(close,3)="" (ref(close,2)<ref(close,4)="" or="" if(ref(close,3)<ref(close,4),1,if(ref(close,4)<ref(close,5),ref(close,1)=REF(CLOSE,5)),IF(REF(CLOSE,5)<ref(close,6),1,ref(close,6)<ref(close,7))));< p="">

BB:=CLOSE<ref(close,1) and="" ref(close,1)="" ref(close,1)REF(CLOSE,3) AND IF(REF(CLOSE,3)>REF(CLOSE,4),1,IF(REF(CLOSE,4)>REF(CLOSE,5),REF(CLOSE,1)>REF(CLOSE,4) OR (REF(CLOSE,2)>REF(CLOSE,4) AND REF(CLOSE,3)<=REF(CLOSE,5)),IF(REF(CLOSE,5)>REF(CLOSE,6),1,REF(CLOSE,6)>REF(CLOSE,7))));

DRAWICON(AA AND CLOSE>REF(OPEN,2),0.99×LOW,1);

DRAWICON(BB AND CLOSE<ref(close,2),high×1.01,2);< p="">

DRAWTEXT(AA AND CLOSE>REF(OPEN,2),LOW×0.98,'三平底翻红'),COLORYELLOW;

DRAWTEXT(BB AND CLOSE<ref(close,2),high×1.02,'三平顶翻绿'),color00ff00;< p="">

宝塔线源代码

STICKLINE(CLOSE>=CLOSE[1],CLOSE,CLOSE[1],9,1),colorred;

STICKLINE(CLOSE<close[1],close,close[1],9,0),colorgreen;< p="">

STICKLINE(CLOSE[1]>=CLOSE[2] AND CLOSE<close[1],close[1],max(close[2],close),9,1),colorred;< p="">

STICKLINE(CLOSE[1]=CLOSE[1],CLOSE[1],MIN(CLOSE[2],CLOSE),9,0),colorgreen;

通达信宝塔线SAR指标公式源码副图

VAR1:=SAR(10,2,20);

S:IF(VAR1>C,VAR1,DRAWNULL),COLORGREEN,CIRCLEDOT;

X:IF(VAR1<c,var1,drawnull),colorred,circledot;< p="">

B1:=REF(C,1);B2:=REF(C,2);

SS:=IF(C>REF(C,1) AND REF(C,1)>=REF(C,2),1,IF(C<ref(c,1) ref(c,1)REF(C,2) AND REF(C,2)>REF(C,1),2,IF(C<ref(c,2) and="" p="" ref(c,2)<ref(c,1),-2,0))));

SM:=IF(REF(SS,1)>0 OR REF(SS,1)<0,REF(SS,1),IF(REF(SS,2)>0 OR REF(SS,2)<0,REF(SS,2),IF(REF(SS,3)>0 OR REF(SS,3)<0,REF(SS,3),IF(REF(SS,4)>0 OR REF(SS,4)<0,REF(SS,4),IF(REF(SS,5)>0 OR REF(SS,5)<0,REF(SS,5),IF(REF(SS,6)>0 OR REF(SS,6)<0,REF(SS,6),IF(REF(SS,7)>0 OR REF(SS,7)<0,REF(SS,7),0)))))));

MC:IF(REF(SS,1)>0 OR REF(SS,1)<0,B2,IF(SM>0,MIN(B1,B2),MAX(B1,B2))),COLORFF00FF;

STICKLINE(SS=1 OR SM>=1 AND SS=0,B1,C,0.8,1),COLORRED;

STICKLINE(SS=-1 OR SM<=-1 AND SS=0,B1,C,0.8,0),COLORFF9000;

STICKLINE(SS=2,B2,C,0.8,1),COLORRED;

STICKLINE(SS=-2,B2,C,0.8,0),COLORFF9000;

STICKLINE((SS=-1 OR SS=-2) AND SM>0,B2,B1,0.8,1),COLORRED;

STICKLINE((SS=1 OR SS=2) AND SM<0,B2,B1,0.8,0),COLORFF9000;

29908