通达信三箱体主图指标主图+选股指标开源
阻力价:HHV(HIGH,19),COLORRED, LINETHICK2;
VAR2:=EMA(VAR1,9);
VAR4:=EMA(C,3);
VAR8:=REF(HHV(CLOSE,480),1);
VARA:=(CLOSE-LLV(CLOSE,981))/(HHV(CLOSE,981)-LLV(CLOSE,981))*100;
VARC:=(CLOSE-LLV(LOW,981))/(HHV(HIGH,981)-LLV(LOW,981))*100;
VARE:=VARC>98.5 OR VARD>98.5;
VAR13:=VARA=0 AND VARC=0 AND VAR6< 0;
VAR15:=VARB=0 OR VARD=0 AND VAR9< 0;
VAR17:=VAR6< 0 AND VAR9< 0;
VAR19:=VAR14 AND VAR16;
VAR1C:=SMA(MAX(CLOSE-REF(CLOSE,1),0),14,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),14,1)*100;
VAR1E:=VAR1B< 20 AND VAR1C< 23 AND VAR1D>35;
VAR20:=REF(CLOSE,1);
VAR22:=SMA(MAX(CLOSE-VAR20,0),13,1)/SMA(ABS(CLOSE-VAR20),13,1)*100;
VAR24:=VAR21< 20 AND VAR22< 23 AND VAR23>35;
VAR27:=VAR18 AND VARF< 1.2 AND VAR17;
VAR2A:=SUM(MAX(0,HIGH-REF(CLOSE,1)),77)/SUM(MAX(0,REF(CLOSE,1)-LOW),77)*100;
VAR2C:=VAR24 AND VAR1F AND COUNT(VAR24,30)=1;
绝对卖点:=(VAR19 OR VARA)AND VARF>23 OR VARE ;
GHWYH:=(CLOSE/REF(CLOSE,1)>1.04 AND (CLOSE>10.8 AND CLOSE< 10.83 OR CLOSE>6.86 AND CLOSE< 6.88 OR CLOSE>13.82 AND CLOSE< 13.84 OR CLOSE>7.28 AND CLOSE< 7.3 OR CLOSE>12.4 AND CLOSE< 12.42 OR CLOSE>22.33 AND CLOSE< 22.35 OR CLOSE>4.68 AND CLOSE< 4.7 OR CLOSE>26.29 AND CLOSE< 26.31 OR CLOSE>7.65 AND CLOSE< 7.67 OR CLOSE>13.4 AND CLOSE< 13.42 OR CLOSE>7.58 AND CLOSE< 7.6 OR CLOSE>20.43 AND CLOSE< 20.45 OR CLOSE>19.57 AND CLOSE< 19.59 OR CLOSE>6.26 AND CLOSE< 6.28 OR CLOSE>7.14 AND CLOSE< 7.16 OR CLOSE>6.61 AND CLOSE< 6.63 OR CLOSE>11.9 AND VOL< 11.92 OR CLOSE>6.7 AND CLOSE< 6.72 OR CLOSE>8.19 AND CLOSE< 8.21));
DRAWTEXT(GHWYH>0,L,'☆追涨'),COLORYELLOW ;
DRAWTEXT(买点>0,L,'扫描神针'),COLORF00FF0;
STICKLINE(VAR2D>0,O,C,10,0), COLORRED;
DRAWICON(COUNT(REF(VAR4,1)< REF(VAR4,2),5)=5 AND VAR4>REF(VAR4,1),L*0.98,4);
DRAWICON(FILTER(REF(VAR4,1)>REF(VAR4,2)AND VAR4< REF(VAR4,1)AND VARF>17 AND VAR1>VAR2,5),H,2);
A1:=REF(C,1)< REF(O,1) AND C>O AND C>REF(O,1) AND O<=REF(C,1);
支撑:MA(REF(LLV(C,30),1),2),COLORLIGREEN,LINETHICK2;
X1B:HHV(C,X1A),COLORFF5500,LINETHICK3;
X1D:=IF(X1C=1,' 1',IF(X1C=2,' 2',IF(X1C=3,' 3',IF(X1C=4,' 4',IF(X1C=5,' 5', IF(X1C=6,' 6',IF(X1C=7,' 7',IF(X1C=8,' 8',IF(X1C=9,' 9',IF(X1C=10,' 10', IF(X1C=11,' 11',IF(X1C=12,' 12',IF(X1C=13,' 13',IF(X1C=14,' 14',IF(X1C=15,' 15', IF(X1C=16,' 16',IF(X1C=17,' 17',IF(X1C=18,' 18',IF(X1C=19,' 19',IF(X1C=20,' 20', IF(X1C=21,' 21',IF(X1C=22,' 22',IF(X1C=23,' 23',IF(X1C=24,' 24',IF(X1C=25,' 25', IF(X1C=26,' 26',IF(X1C=27,' 27',IF(X1C=28,' 28',IF(X1C=29,' 29',IF(X1C=30,' 30',' 0'))))))))))))))))))))))))))))));
X2A:=30;
X2C:=IF(ISLASTBAR,BARSLAST(C=CONST(X2B))+1,1/0);
X2E:DRAWTEXT(ISLASTBAR,X2B,X2D),COLORFF00FF;
源码
来函数检测结果如下:
该公式没有未来函数
解密、定制、编写股票指标请联系QQ或微信同号:88652583
相关股票指标公式
原理解析:
输出阻力价:19日内最高价最高值,画红色, 线宽为2
VAR2赋值:VAR1的9日指数移动平均
VAR4赋值:C的3日指数移动平均
VAR8赋值:REF(480日内收盘价最高值,1)
VARA赋值:(收盘价-981日内收盘价最低值)/(981日内收盘价最高值-981日内收盘价最低值)*100
VARC赋值:(收盘价-981日内最低价最低值)/(981日内最高价最高值-981日内最低价最低值)*100
VARE赋值:VARC>98.5 OR VARD>98.5
VAR13赋值:VARA=0 AND VARC=0 AND VAR6< 0
VAR15赋值:VARB=0 OR VARD=0 AND VAR9< 0
VAR17赋值:VAR6< 0 AND VAR9< 0
VAR19赋值:VAR14 AND VAR16
VAR1C赋值:SMA(收盘价-1日前的收盘价和0较大值,14,1)/SMA(收盘价-1日前的收盘价的绝对值,14,1)*100
VAR1E赋值:VAR1B< 20 AND VAR1C< 23 AND VAR1D>35
VAR20:=1日前的收盘价
VAR22:=SMA(收盘价-VAR20和0较大值,13,1)/SMA(收盘价-VAR20的绝对值,13,1)*100
VAR24:=VAR21< 20 AND VAR22< 23 AND VAR23>35
VAR27:=VAR18 AND VARF< 1.2 AND VAR17
VAR2A:=77的0和最高价-1日前的收盘价较大值日累和/77的0和1日前的收盘价-最低价较大值日累和*100
VAR2C:=VAR24 AND VAR1F AND 统计30日满足VAR24的天数=1
绝对卖点赋值:(VAR19 OR VARA)AND VARF>23 OR VARE
GHWYH赋值:(收盘价/1日前的收盘价>1.04 AND (收盘价>10.8 AND 收盘价< 10.83 OR 收盘价>6.86 AND 收盘价< 6.88 OR 收盘价>13.82 AND 收盘价< 13.84 OR 收盘价>7.28 AND 收盘价< 7.3 OR 收盘价>12.4 AND 收盘价< 12.42 OR 收盘价>22.33 AND 收盘价< 22.35 OR 收盘价>4.68 AND 收盘价< 4.7 OR 收盘价>26.29 AND 收盘价< 26.31 OR 收盘价>7.65 AND 收盘价< 7.67 OR 收盘价>13.4 AND 收盘价< 13.42 OR 收盘价>7.58 AND 收盘价< 7.6 OR 收盘价>20.43 AND 收盘价< 20.45 OR 收盘价>19.57 AND 收盘价< 19.59 OR 收盘价>6.26 AND 收盘价< 6.28 OR 收盘价>7.14 AND 收盘价< 7.16 OR 收盘价>6.61 AND 收盘价< 6.63 OR 收盘价>11.9 AND 成交量< 11.92 OR 收盘价>6.7 AND 收盘价< 6.72 OR 收盘价>8.19 AND 收盘价< 8.21))
当满足条件GHWYH>0时,在L和'☆追涨'位置书写文字
当满足条件买点>0时,在L和'扫描神针'位置书写文字
当满足条件VAR2D>0时,在O和C之间画柱状线
DRAWICON(COUNT(1日前的VAR4< 2日前的VAR4,5)=5 AND VAR4>1日前的VAR4,L*0.98,4)
DRAWICON(FILTER(1日前的VAR4>2日前的VAR4AND VAR4< 1日前的VAR4AND VARF>17 AND VAR1>VAR2,5),H,2)
A1赋值:1日前的C< 1日前的O AND C>O AND C>1日前的O AND O<=1日前的C
输出支撑:MA(REF(30日内C最低值,1),2),COLORLIGREEN, 线宽为2
输出X1B:X1A日内C最高值,COLORFF5500, 线宽为3
X1D赋值:IF(X1C=1,' 1',IF(X1C=2,' 2',IF(X1C=3,' 3',IF(X1C=4,' 4',IF(X1C=5,' 5', IF(X1C=6,' 6',IF(X1C=7,' 7',IF(X1C=8,' 8',IF(X1C=9,' 9',IF(X1C=10,' 10', IF(X1C=11,' 11',IF(X1C=12,' 12',IF(X1C=13,' 13',IF(X1C=14,' 14',IF(X1C=15,' 15', IF(X1C=16,' 16',IF(X1C=17,' 17',IF(X1C=18,' 18',IF(X1C=19,' 19',IF(X1C=20,' 20', IF(X1C=21,' 21',IF(X1C=22,' 22',IF(X1C=23,' 23',IF(X1C=24,' 24',IF(X1C=25,' 25', IF(X1C=26,' 26',IF(X1C=27,' 27',IF(X1C=28,' 28',IF(X1C=29,' 29',IF(X1C=30,' 30',' 0'))))))))))))))))))))))))))))))
X2A赋值:30
X2C赋值:IF(ISLASTBAR,上次C=CONST(X2B距今天数)+1,1/0)
当满足条件ISLASTBAR时,在X2B和X2D位置书写文字
源码