当前位置: 网站首页 > 股票软件公式 > 同花顺公式 > 文章 当前位置: 同花顺公式 > 文章

同花顺源码:布林宝塔,杀庄公式,抄底逃顶自用

点击: 次    来源:顶尖财经    作者:股市狙击 - 小 + 大

1、布林宝塔

N:=13;

MID :  MA(CLOSE,N);
UPPER: MID + 2*STD(CLOSE,N);
LOWER: MID - 2*STD(CLOSE,N);
MA1:=MA(CLOSE,5);
MA2:=MA(CLOSE,10);
MA3:=MA(CLOSE,20);
MA4:=MA(CLOSE,60);
MA5:=MA(CLOSE,120);
MA6:=MA(CLOSE,250);
VAR1:=CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2);
VAR2:=REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR3:=REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR4:=REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR5:=REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR6:=REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR7:=REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR8:=REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR9:=REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARA:=REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VARB:=REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARC:=REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),8,0),colorred;
VARD:=CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2);
VARE:=REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VARF:=REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR10:=REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR11:=REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR12:=REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR13:=REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR14:=REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR15:=REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR16:=REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
VAR17:=REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2);
VAR18:=REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2);
ttt:STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),8,0),colorgreen;
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),8,0),colorgreen;
VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),8,0) ,coloryellow;
VAR1A:=REF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,1) AND VARD;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),8,0),colorlired;
上1:=IF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,MAX(CLOSE,REF(CLOSE,1)),0);
上2:=IF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,MAX(CLOSE,REF(CLOSE,1)),0);
上3:=IF(VAR19,MAX(REF(CLOSE,1),REF(CLOSE,2)),0);
上4:=IF(VAR1A,MAX(REF(CLOSE,1),REF(CLOSE,2)),0);
中1:=IF(VAR19,MAX(REF(CLOSE,1),REF(CLOSE,2)),
IF(VAR1A,MIN(REF(CLOSE,1),REF(CLOSE,2)),0));
下1:=IF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC
,MIN(CLOSE,REF(CLOSE,1)),MAX(CLOSE,REF(CLOSE,1)));
下2:=IF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18
,MIN(CLOSE,REF(CLOSE,1)),MAX(CLOSE,REF(CLOSE,1)));
下3:=IF(VAR19,MIN(REF(CLOSE,1),REF(CLOSE,2)),MAX(REF(CLOSE,1),REF(CLOSE,2)));
下4:=IF(VAR1A,MIN(REF(CLOSE,1),REF(CLOSE,2)),MAX(REF(CLOSE,1),REF(CLOSE,2)));
上:MAX(MAX(上1,上2),MAX(上3,上4)),NODRAW;
中:=中1,NODRAW;
下:MIN(MIN(下1,下2),MIN(下3,下4)),NODRAW;



2、杀庄公式

低吸高抛波段操作,图中有详情,仔细擦看,小心操作( 顶尖财经 股票学院: http://58188.com )

 VAR2:=1/WINNER(CLOSE);

VAR3:=MA(CLOSE,13);
VAR4:=100-ABS((CLOSE-VAR3)/VAR3*100);
VAR5:=LLV(LOW,75);
VAR6:=HHV(HIGH,75);
VAR7:=(VAR6-VAR5)/100;
VAR8:=SMA((CLOSE-VAR5)/VAR7,20,1);
VAR9:=SMA((OPEN-VAR5)/VAR7,20,1);
VARA:=3*VAR8-2*SMA(VAR8,15,1);
VARB:=3*VAR9-2*SMA(VAR9,15,1);
VARC:=100-VARB;
看实力: (100-VARA),COLOR0099FF,LINETHICK2;
散户: MA(WINNER(CLOSE*0.95)*100,3),coloryellow, ;
新庄: (100-IF(VAR2>5,IF(VAR2<100,VAR2,VAR4-10),0)),colorgreen , ;
VARD:=散户>VAR4;
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);
小心断裂:(IF(VAR23>=200 AND VAR22>=150,15,IF(VAR23<=-200 AND VAR22<=-150,-15,VAR25))+50),COLORCC9900 ,LINETHICK2 ,CROSSDOT;
STICKLINE(VARD,VAR4,散户,5,0),, ;STICKLINE(1,散户,0,1,0),coloryellow , ;
STICKLINE(1,新庄,100,1,0),colorgreen, ;
STICKLINE(VAR20,0,80,5,0),colorred,LINETHICK3 ;
DRAWTEXT(CROSS(VAR20,0.5) AND COUNT(VAR20=1,10)=1,60,'有钱不赚是傻蛋!'),coloryellow,LINETHICK2;
DRAWTEXT(CROSS(VARD,0.5) AND COUNT(VARD=1,10)=1,70,'赚钱我走啦!'), , ;
VAR26:=(CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100;
VAR27:=REVERSE(VAR26);
VAR28:=SMA(VAR26,3,1);
波段王: SMA(VAR28,3,1),COLORFF00FF,LINETHICK2;
波段鬼: SMA(波段王,3,1),coloryellow,LINETHICK2;
地狱:IF(CROSS(波段王,波段鬼) AND 波段王<40,35,0),COLOR0066FF ,LINETHICK2 ;
天堂:IF(CROSS(波段鬼,波段王) AND 波段鬼>75,70,100),colorgreen ,LINETHICK2 ;
DRAWTEXT(CROSS(波段王,波段鬼) AND 波段王<40,25,'逢低吸呐 !'),colorwhite , ;
DRAWTEXT(CROSS(波段鬼,波段王) AND 波段鬼>75,85,'逢高减磅!'),COLORFFFF00 , ;



3、抄底逃顶自用

 JJ:=(CLOSE+HIGH+LOW)/3;

A:=EMA(JJ,5);
B:=REF(A,1);
持股:=STICKLINE(A>B,A,B,6,0),COLOR00FFFF;
STICKLINE(A>B,A,B,6,0),COLOR00FFFF;
弃股:=STICKLINE(A<=B,A,B,6,0),COLORA00000;
STICKLINE(A<=B,A,B,6,0),colorblue;
JDA:=(3*CLOSE+OPEN+LOW+HIGH)/6;
JDB:(20*JDA+19*REF(JDA,1)+18*REF(JDA,2)+17*REF(JDA,3)+16*REF(JDA,4)+15*REF(JDA,5)+14*REF(JDA,6)
+13*REF(JDA,7)+12*REF(JDA,8)+11*REF(JDA,9)+10*REF(JDA,10)+9*REF(JDA,11)+8*REF(JDA,12)
+7*REF(JDA,13)+6*REF(JDA,14)+5*REF(JDA,15)+4*REF(JDA,16)+3*REF(JDA,17)+2*REF(JDA,18)+
REF(JDA,20))/210,coloryellow;
JDC:MA(JDB,5),colorred;
偏离:(C-JDB)/JDB*100, colorgreen;
涨幅: (C-REF(C,1))/REF(C,1)*100;
时间: DATE;
收盘:C;
DRAWICON(CROSS(JDB,JDC),MIN(C,O),1),coloryellow;
DRAWICON (CROSS(JDC,JDB), MAX(C,O),2),colorgreen;
DRAWTEXT (JDB>REF(JDB,1) AND REF(JDB,1)<REF(JDB,2),MIN(C,O),'拐头'),coloryellow;
STICKLINE (涨幅>7,0.33*C+0.67*O,0.67*C+0.33*O,12,0),colorred;
Z:=MA(C,120);
VAR1:=(MA(H,5)-Z)/Z;
VAR2:=MA((CLOSE-LLV(LOW,10))/(HHV(HIGH,10)-LLV(LOW,10))*100,3);
D1:=DRAWTEXT(CROSS(95,VAR2) AND VAR1>0.3,1.01*HIGH ,'★S'),colorred;
DRAWTEXT(CROSS(95,VAR2) AND VAR1>0.3,1.01*HIGH ,'★S'),colorred;
D2:=DRAWTEXT( CROSS(93,VAR2) AND HHV(H,30)/LLV(L,30)>1.1 AND REF(Z,1)/Z>0.997 ,1.01*HIGH ,'★S'),colorgreen;
DRAWTEXT( CROSS(93,VAR2) AND HHV(H,30)/LLV(L,30)>1.1 AND REF(Z,1)/Z>0.997 ,1.01*HIGH ,'★S'),colorgreen;
D3:=DRAWTEXT(CLOSE<Z AND Z<REF(Z,1) AND REF(VAR2,1)>90 AND VAR2<REF(VAR2,1) AND REF(VAR2,1)>REF(VAR2,2) ,1.01*HIGH,'★S'),colorblue;
DRAWTEXT(CLOSE<Z AND Z<REF(Z,1) AND REF(VAR2,1)>90 AND VAR2<REF(VAR2,1) AND REF(VAR2,1)>REF(VAR2,2) ,1.01*HIGH,'★S'),colorblue;
VAR3:=(MA(C,5)-Z)/Z;
VAR4:=MA((CLOSE-LLV(LOW,20))/(HHV(HIGH,20)-LLV(LOW,20))*100,3);
D4:=DRAWTEXT(CLOSE>Z AND REF(VAR4,1)<30 AND VAR4>REF(VAR4,1) AND REF(VAR4,1)<REF(VAR4,2) ,0.99*LOW ,'★B'),colorred;
DRAWTEXT(CLOSE>Z AND REF(VAR4,1)<30 AND VAR4>REF(VAR4,1) AND REF(VAR4,1)<REF(VAR4,2) ,0.99*LOW ,'★B'),colorred;
D5:=DRAWTEXT(REF(VAR4,1)<7 AND VAR4>REF(VAR4,1) AND REF(VAR4,1)<REF(VAR4,2) AND VAR3<-0.1,0.99*LOW ,'★B'),colorgreen;
DRAWTEXT(REF(VAR4,1)<7 AND VAR4>REF(VAR4,1) AND REF(VAR4,1)<REF(VAR4,2) AND VAR3<-0.1,0.99*LOW ,'★B'),colorgreen;
D6:=DRAWTEXT(CROSS(VAR4,5) AND VAR3<-0.3,0.99*LOW ,'★B'),colorblue;
DRAWTEXT(CROSS(VAR4,5) AND VAR3<-0.3,0.99*LOW ,'★B'),colorblue;
 

上一篇:同花顺源码:宝塔TOWER,超短买就完事,短线拐头

下一篇:同花顺源码:资金抄底,多空趋势,趋势A