扫描主力通达信公式 副图 源码附图
AVPRICE:=(2*OPEN+2*CLOSE+2*HIGH+2*LOW)/8;
INDEXAVP:=(2*INDEXH+2*INDEXL+2*INDEXO+2*INDEXC)/8;
F:=(AVPRICE - REF(AVPRICE,1))/REF(AVPRICE,1);
F1:=(INDEXAVP - REF(INDEXAVP,1))/REF(INDEXAVP,1);
类比参数3:=(SUM(F,10) + SUM(F1,10))/10*1000;
类比大盘参数:=IF(类比参数3 > 0,类比参数3,0);
类比参数2:=IF(类比参数3 < 0,-类比参数3,0);
STICKLINE(类比参数2 AND (150 - 类比参数2)>0,150,150 - 类比参数2,6,0),COLOR008000;
STICKLINE(类比大盘参数 AND (150 - 类比大盘参数)>0,150,150 - 类比大盘参数,6,0),COLORFF00FF;
AA:=AVPRICE;{股票指标网}
BB:=((VOL)*((AA)*(2) - HIGH - LOW))/(HIGH - LOW);
CC:=IF((HIGH = LOW) AND (AA < REF(AA,1)),((-1))*(VOL),VOL);
A:=IF((HIGH = LOW),CC,BB);
B:=SUM(A,11);
BBD:=(((B)/((CAPITAL)*(11)))*(10000));
BB1:=IF((BBD < 150) AND (BBD > (-150)),BBD,150);
买方能量指标:=IF((BB1 > 0),BB1,0);
STICKLINE((BB1 > 0),0,买方能量指标,6,0),COLORYELLOW;
STICKLINE((BB1 < 0),0,(-BB1),6,0),COLOR00FF00;
主动买量:IF((BB1 > 0),BB1,0),COLORYELLOW,LINETHICK0;
主动卖量:IF((BB1<0),BB1,0),COLOR00FF00,LINETHICK0;
A16:=(SUM((AVPRICE)*(VOL),16))/(SUM(VOL,16));
A11:=(SUM((AVPRICE)*(VOL),11))/(SUM(VOL,11));
A6:=(SUM((AVPRICE)*(VOL),6))/(SUM(VOL,6));
A7:=(SUM((AVPRICE)*(VOL),7) - (AVPRICE)*(VOL))/(SUM(VOL,7) - VOL);
A0:=((A11 - A16)/(AVPRICE))*(1000);
A00:=IF((A0 > 50),50,IF((A0 < (-50)),(-50),A0));
A1:=((A6 - A11)/(AVPRICE))*(1000);
AA11:=IF((A1 > 50),50,IF((A1 < (-50)),(-50),A1));
A2:=((((A6 - A7)/(A7))*(5))/(4))*(1000);
A22:=IF((A2 > 50),50,IF((A2 < (-50)),(-50),A2));
刻度线3:=(A00 + AA11 + A22);
趋势线:=IF((刻度线3 > 0),刻度线3,0);
兰刻度线:=IF((刻度线3 < 0),刻度线3,0);
做多趋势:趋势线,COLOR0000FF;
做空趋势:(-兰刻度线),COLORFF0000;
STICKLINE(趋势线,0,趋势线,2,0),COLORRED;
STICKLINE(兰刻度线,0,(-兰刻度线),2,0),COLORFF0000;
强弱界:50,COLORFFFFFF;
触顶线:145,COLOR0000FF,LINETHICK3;
未来函数检测结果如下:
该公式包含未来函数:CAPITAL
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式
原理解析:
AVPRICE赋值:(2*开盘价+2*收盘价+2*最高价+2*最低价)/8
INDEXAVP赋值:(2*INDEXH+2*INDEXL+2*INDEXO+2*INDEXC)/8
F赋值:(AVPRICE - 1日前的AVPRICE)/1日前的AVPRICE
F1:=(INDEXAVP - 1日前的INDEXAVP)/1日前的INDEXAVP
类比参数3赋值:(10的F日累和 + 10的F1日累和)/10*1000
如果类比参数3 > 0返回类比参数3否则返回0
如果类比参数3 < 0返回-类比参数3否则返回0
STICKLINE(类比参数2 AND (150 - 类比参数2)>0,150,150 - 类比参数2,6,0),COLOR008000
STICKLINE(类比大盘参数 AND (150 - 类比大盘参数)>0,150,150 - 类比大盘参数,6,0),COLORFF00FF
AA赋值:AVPRICE
{股票指标网}
BB赋值:((成交量)*((AA)*(2) - 最高价 - 最低价))/(最高价 - 最低价)
CC赋值:IF((最高价 = 最低价) AND (AA < 1日前的AA),((-1))*(成交量),成交量)
A赋值:IF((最高价 = 最低价),CC,BB)
B赋值:11的A日累和
BBD:=(((B)/((CAPITAL)*(11)))*(10000))
BB1:=IF((BBD < 150) AND (BBD > (-150)),BBD,150)
买方能量指标赋值:IF((BB1 > 0),BB1,0)
STICKLINE((BB1 > 0),0,买方能量指标,6,0),画黄色
STICKLINE((BB1 < 0),0,(-BB1),6,0),COLOR00FF00
输出主动买量:IF((BB1 > 0),BB1,0),画黄色,LINETHICK0
输出主动卖量:IF((BB1<0),BB1,0),COLOR00FF00,LINETHICK0
A16:=(SUM((AVPRICE)*(成交量),16))/(SUM(成交量,16))
A11:=(SUM((AVPRICE)*(成交量),11))/(SUM(成交量,11))
A6:=(SUM((AVPRICE)*(成交量),6))/(SUM(成交量,6))
A7:=(SUM((AVPRICE)*(成交量),7) - (AVPRICE)*(成交量))/(SUM(成交量,7) - 成交量)
A0:=((A11 - A16)/(AVPRICE))*(1000)
A00:=IF((A0 > 50),50,IF((A0 < (-50)),(-50),A0))
A1:=((A6 - A11)/(AVPRICE))*(1000)
AA11:=IF((A1 > 50),50,IF((A1 < (-50)),(-50),A1))
A2:=((((A6 - A7)/(A7))*(5))/(4))*(1000)
A22:=IF((A2 > 50),50,IF((A2 < (-50)),(-50),A2))
刻度线3赋值:(A00 + AA11 + A22)
趋势线赋值:IF((刻度线3 > 0),刻度线3,0)
兰刻度线赋值:IF((刻度线3 < 0),刻度线3,0)
输出做多趋势:趋势线,COLOR0000FF
输出做空趋势:(-兰刻度线),COLORFF0000
当满足条件趋势线时,在0和趋势线之间画柱状线
STICKLINE(兰刻度线,0,(-兰刻度线),2,0),COLORFF0000
输出强弱界:50,COLORFFFFFF
输出触顶线:145,COLOR0000FF, 线宽为3