通达信PVT指标分析指标副图源码
PVTT:=SUM((CLOSE-REF(CLOSE,1))/REF(CLOSE,1)*VOL,0),COLORYELLOW,LINETHICK1;
PVT3:=EMA(PVTT,3),COLORYELLOW,LINETHICK2;
PVT6:=EMA(PVTT,6),COLORRED,LINETHICK2;
PVT12:=EMA(PVTT,12),COLORGREEN,LINETHICK2;
PVT24:=EMA(PVTT,24),COLORGREEN,LINETHICK2;
STICKLINE(PVT12>PVT24,-100,-90,11,0),COLORGREEN,LINETHICK1;
STICKLINE(PVT6>PVT24,-89,-79,11/4,0),COLORGREEN,LINETHICK1;
STICKLINE(PVT3>PVT24,-78,-68,11/4,0),COLORGREEN,LINETHICK1;
STICKLINE(PVT6>PVT12,-67,-57,11/4,0),COLORRED,LINETHICK1;
STICKLINE(PVT3>PVT12,-56,-46,11/4,0),COLORRED,LINETHICK1;
STICKLINE(PVT3>PVT6,-45,-35,11/4,0),COLORRED,LINETHICK1;
STICKLINE(PVT12>REF(PVT12,1),-34,-24,11/4,0),COLORGREEN,LINETHICK1;
STICKLINE(PVT6>REF(PVT6,1),-23,-13,11/4,0),COLORGREEN,LINETHICK1;
STICKLINE(PVT3>REF(PVT3,1),-12,-2,11/4,0),COLORGREEN,LINETHICK1;
LLJ:=(C-REF(CLOSE,1))*V/C/1000;
DIFF20:=EMA(LLJ,20),COLORGREEN,LINETHICK1;
DIFF10:=EMA(LLJ,10),COLORRED,LINETHICK1;
DIFF5:=EMA(LLJ,5),COLORYELLOW,LINETHICK3;
STICKLINE(DIFF20>0,2,12,11/4,0),COLORRED,LINETHICK1;
STICKLINE(DIFF10>0,13,23,11/4,0),COLORRED,LINETHICK1;
STICKLINE(DIFF5>0,24,34,11/4,0),COLORRED,LINETHICK1;
STICKLINE(DIFF10>DIFF20,35,45,11/4,0),COLORGREEN,LINETHICK1;
STICKLINE(DIFF5>DIFF20,46,56,11/4,0),COLORGREEN,LINETHICK1;
STICKLINE(DIFF5>DIFF10,57,67,11/4,0),COLORGREEN,LINETHICK1;
STICKLINE(DIFF20>REF(DIFF20,1),68,78,11/4,0),COLORRED,LINETHICK1;
STICKLINE(DIFF10>REF(DIFF10,1),79,89,11/4,0),COLORRED,LINETHICK1;
STICKLINE(DIFF5>REF(DIFF5,1),90,100,11/4,0),COLORRED,LINETHICK1;
LC:=REF(CLOSE,1);
RSI5:=((SMA(MAX((CLOSE - LC),0),5,1) / SMA(ABS((CLOSE - LC)),5,1)) * 100);
TR8:=SUM(MAX(MAX((HIGH - LOW),ABS((HIGH - REF(CLOSE,1)))),ABS((LOW - REF(CLOSE,1)))),10);
HD:=(HIGH - REF(HIGH,1));
LD:=(REF(LOW,1) - LOW);
DMP:=SUM(IF(((HD > 0) AND (HD > LD)),HD,0),10);
DMM:=SUM(IF(((LD > 0) AND (LD > HD)),LD,0),10);
PDI:=((DMP * 100) / TR8);
MDI:=((DMM * 100) / TR8);
ADX:=MA(((ABS((MDI - PDI)) / (MDI + PDI)) * 100),5);
AV:=(RSI5 + ADX);
DXR:=(((ADX + REF(ADX,5)) / 2) + RSI5);
WR10:=((100 * (HHV(HIGH,10) - CLOSE)) / (HHV(HIGH,10) - LLV(LOW,10)));
NEWVOL:=(RSI5 - WR10);
阶段底部:=(AV + NEWVOL);
趋势线:=LLV(阶段底部,1)-100;
DIFF:=(EMA(CLOSE,12) - EMA(CLOSE,26))*50;
DEA:=EMA(DIFF,9);
MACD:=2*(DIFF-DEA);
KDEA:=SMA(MACD,5,2);
MMLD:=2*(MACD-KDEA);
KDEAA:=SMA(MMLD,5,2);
MMMLD:=2*(MMLD-KDEAA);
KDEAAA:=SMA(MMMLD,5,2);
LD5:=2*(MMMLD-KDEAAA);
CKDEA:=SMA(MACD,3,2);
CMMLD:=3*(MACD-CKDEA);
CKDEAA:=SMA(CMMLD,3,2);
CMMMLD:=4*(CMMLD-CKDEAA);
CKDEAAA:=SMA(CMMMLD,3,2);
LD3:= 5*(CMMMLD-CKDEAAA);
MM:=HHV(ABS(DIFF),10);
M:=DIFF/MM*100;
MMM:=HHV(ABS(DEA),10);
A:=DEA/MMM*100;
MMMM:=HHV(ABS(MACD),10);
D:=MACD/MMMM*100;
MMMMM:=HHV(ABS(LD3),10);
L3:LD3/MMMMM*100;
MMMMMM:=HHV(ABS(LD5),10);
L5:LD5/MMMMMM*100;
来函数检测结果如下:
该公式没有未来函数
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式
原理解析:
PVTT赋值:SUM((收盘价-1日前的收盘价)/1日前的收盘价*成交量,0),画黄色,LINETHICK1
PVT3赋值:PVTT的3日指数移动平均,画黄色, 线宽为2
PVT6赋值:PVTT的6日指数移动平均,COLORRED, 线宽为2
PVT12赋值:PVTT的12日指数移动平均,画绿色, 线宽为2
PVT24赋值:PVTT的24日指数移动平均,画绿色, 线宽为2
当满足条件PVT12>PVT24时,在-100和-90之间画柱状线
当满足条件PVT6>PVT24时,在-89和-79之间画柱状线
当满足条件PVT3>PVT24时,在-78和-68之间画柱状线
当满足条件PVT6>PVT12时,在-67和-57之间画柱状线
当满足条件PVT3>PVT12时,在-56和-46之间画柱状线
当满足条件PVT3>PVT6时,在-45和-35之间画柱状线
STICKLINE(PVT12>1日前的PVT12,-34,-24,11/4,0),画绿色,LINETHICK1
STICKLINE(PVT6>1日前的PVT6,-23,-13,11/4,0),画绿色,LINETHICK1
STICKLINE(PVT3>1日前的PVT3,-12,-2,11/4,0),画绿色,LINETHICK1
LLJ赋值:(C-1日前的收盘价)*V/C/1000
DIFF20赋值:LLJ的20日指数移动平均,画绿色,LINETHICK1
DIFF10赋值:LLJ的10日指数移动平均,COLORRED,LINETHICK1
DIFF5赋值:LLJ的5日指数移动平均,画黄色, 线宽为3
当满足条件DIFF20>0时,在2和12之间画柱状线
当满足条件DIFF10>0时,在13和23之间画柱状线
当满足条件DIFF5>0时,在24和34之间画柱状线
当满足条件DIFF10>DIFF20时,在35和45之间画柱状线
当满足条件DIFF5>DIFF20时,在46和56之间画柱状线
当满足条件DIFF5>DIFF10时,在57和67之间画柱状线
STICKLINE(DIFF20>1日前的DIFF20,68,78,11/4,0),COLORRED,LINETHICK1
STICKLINE(DIFF10>1日前的DIFF10,79,89,11/4,0),COLORRED,LINETHICK1
STICKLINE(DIFF5>1日前的DIFF5,90,100,11/4,0),COLORRED,LINETHICK1
LC赋值:1日前的收盘价
RSI5赋值:((SMA(MAX((收盘价 - LC),0),5,1) / SMA((收盘价 - LC的绝对值),5,1)) * 100)
TR8赋值:SUM(MAX(MAX((最高价 - 最低价),(最高价 - 1日前的收盘价的绝对值)),ABS((最低价 - 1日前的收盘价))),10)
HD赋值:(最高价 - 1日前的最高价)
LD赋值:(1日前的最低价 - 最低价)
DMP赋值:SUM(IF(((HD > 0) AND (HD > LD)),HD,0),10)
DMM赋值:SUM(IF(((LD > 0) AND (LD > HD)),LD,0),10)
PDI赋值:((DMP * 100) / TR8)
MDI赋值:((DMM * 100) / TR8)
ADX赋值:MA((((MDI - PDI的绝对值) / (MDI + PDI)) * 100),5)
AV赋值:(RSI5 + ADX)
DXR赋值:(((ADX + 5日前的ADX) / 2) + RSI5)
WR10赋值:((100 * (10日内最高价最高值 - 收盘价)) / (10日内最高价最高值 - 10日内最低价最低值))
NEWVOL赋值:(RSI5 - WR10)
阶段底部赋值:(AV + NEWVOL)
趋势线赋值:1日内阶段底部最低值-100
DIFF赋值:(收盘价的12日指数移动平均 - 收盘价的26日指数移动平均)*50
DEA赋值:DIFF的9日指数移动平均
MACD赋值:2*(DIFF-DEA)
MACD的5日[2日权重]移动平均
MMLD赋值:2*(MACD-KDEA)
MMLD的5日[2日权重]移动平均
MMMLD赋值:2*(MMLD-KDEAA)
MMMLD的5日[2日权重]移动平均
LD5:=2*(MMMLD-KDEAAA)
MACD的3日[2日权重]移动平均
CMMLD赋值:3*(MACD-CKDEA)
CMMLD的3日[2日权重]移动平均
CMMMLD赋值:4*(CMMLD-CKDEAA)
CMMMLD的3日[2日权重]移动平均
LD3:= 5*(CMMMLD-CKDEAAA)
MM赋值:HHV(DIFF的绝对值,10)
M赋值:DIFF/MM*100
MMM赋值:HHV(DEA的绝对值,10)
A赋值:DEA/MMM*100
MMMM赋值:HHV(MACD的绝对值,10)
D赋值:MACD/MMMM*100
MMMMM赋值:HHV(LD3的绝对值,10)
输出L3:LD3/MMMMM*100
MMMMMM赋值:HHV(LD5的绝对值,10)
输出L5:LD5/MMMMMM*100