成交量指标公式源码?
一、成交量指标公式源码?
成交量指标的公式源码:
A03:=(EMA((AMOUNT/100000),1)/3);
A04:=(WINNER(CLOSE)/ 0.3);
A05:=IF((BARSCOUNT(CLOSE) >100),A03,A04);
量:A05 LINETHICK2 ;
动量: (EMA(量, 13.000) * 1.5)LINETHICK2;
A01:=IF((量 > 动量),量,0);
A08:=BARSLAST((A01 > 0));
A09:=REF(量,A08);
趋势:IF((量 <= A01),量,A09),LINETHICK2,COLORRED;
盘整天数:BARSLAST((A01 > 0)),LINETHICK0,COLORMAGENTA;
量价同行:IF(趋势>量,趋势,DRAWNULL),COLORCYAN,LINETHICK2;
A0D:=((((REF(量, 1.000) = REF(趋势, 1)) AND (量 >= REF(量, 1))) AND (量 >= 动量)) AND (REF(量, 1) <= REF(量, 2)));
量价突破选股:IF(((((量 = 趋势) AND (CLOSE > REF(CLOSE, 1))) AND (量 > REF(量, 1))) AND (REF(A08, 2) > 0)), 888,0),LINETHICK0;
量价同行选股:IF((量 = 趋势), 888,0)LINETHICK0;
量价背离选股:IF((REF(((动量 > REF(动量,1)) AND (MA(CLOSE, 5) < REF(MA(CLOSE, 5), 1))), 1) AND 量价突破选股), 888,0),LINETHICK0;
再次上攻选股:IF(A0D, 888,0),LINETHICK0;
DRAWICON(量价突破选股>0,量,9);
DRAWICON(A0D>0,量,6);
DRAWTEXT(再次上攻选股>0,(量*0.7),'再次上攻'),COLORMAGENTA;
DRAWTEXT(量价背离选股>0,(量*1.149),'背离后上攻'),COLORGREEN;
DRAWTEXT(量价突破选股>0,(量*0.699),'上攻'),COLORCYAN。
二、益马成交量指标源码?
益马成交量指标是一个技术分析指标,它可以用来确认股票价格趋势的强弱。以下是该指标的 Python 代码实现:
```python
def yima_volume(data, days=21, ref_days=63):
# 计算收盘价格的波动性
volatility = data['Close'].rolling(window=days).std()
# 计算基准线
base_line = data['Close'].rolling(window=ref_days).mean()
# 计算中心线
center_line = (data['Close'] - base_line) / (volatility * 2)
# 计算成交量加权移动平均线
weighted_vol = data['Volume'] * data['Close']
center_line = center_line.rolling(window=days).sum() / \
data['Volume'].rolling(window=days).sum()
# 计算标准差
sd_line = center_line.rolling(window=days).std()
return center_line, sd_line
```
代码中 `data` 应该是一个包含开盘价、最高价、最低价、收盘价和成交量数据的 DataFrame,`days` 和 `ref_days` 分别表示计算成交量加权移动平均线和计算基准线的时间窗口大小。返回值是一个包含中心线和标准差的元组。
三、mse成交量指标公式源码?
LC:=REF(C,1);
VVA:=IF(C>REF(C,1),V,-V);
OBV18:=SUM(IF(C=REF(C,1),0,VVA),18);
XXV:=IF(C>LC,SUM(V,18),0),COLOR0000CC;
YYV:=IF(C<LC,SUM(V,18),0),COLOR00CC00;
SS0:=IF(C>LC,HHV(REF(V,1),18),0);
SS1:=IF(C<LC,HHV(REF(V,1),18),0);
CCI:=((C-MA(C,14))/(0.015*AVEDEV(C,14)))/4+50,COLORFFCCCC;
RSI:=SMA(MAX(C-LC,0),6,1)/SMA(ABS(C-LC),6,1)*150-30,COLORCC9900;
K9:=SMA((C-LLV(L,9))/(HHV(H,9)-LLV(L,9))*100,3,1),COLOR00CCCC;
D9:=SMA(K9,3,1),COLOR00CC00;
J:=3*K9-2*D9,COLORFF3399,LINETHICK1;
VAR01:=DYNAINFO(17)*REF(MA(V,5),1);
VAR02:=DYNAINFO(7)=C AND DYNAINFO(10)=AMOUNT;
预V1:=IF(DYNAINFO(7)=C AND DYNAINFO(10)=AMOUNT,VAR01,VAR02);
预量:=IF(V>=预V1,V,预V1);
VA:=IF(C>REF(C,1),预量,-预量);
换手率:10000*VOL/FINANCE(7),NODRAW,COLORRED;
周换手率:SUM(VOL/CAPITAL*100,5);
月换手率:SUM(VOL/CAPITAL*100,20);
WOL:=IF(CURRBARSCOUNT=1 AND PERIOD=5,VOL*240/FROMOPEN,DRAWNULL),NODRAW;
STICKLINE(CURRBARSCOUNT=1 AND PERIOD=5,WOL,0,3,-1),COLORFFFFFF;
VVOL:=IF(CURRBARSCOUNT=1 AND PERIOD=5,VOL*240/FROMOPEN,DRAWNULL),NODRAW;
STICKLINE(CURRBARSCOUNT=1 AND PERIOD=5,VVOL,0,-1,-1),COLOR00C0C0;
VOLUME:VOL,VOLSTICK;
主力启动线:MA(VOLUME,5),COLORRED;
主力洗盘线:MA(VOLUME,35),COLORYELLOW;
生命线:=MA(VOLUME,10);
资金异动线:MA(VOLUME,135),COLORGREEN;
AA:=VOL>=REF(V,1)*1.91 && C>REF(C,1);
AAA:=VOL>=REF(V,1)*4 && C>REF(C,1);
AA1:=VOL<REF(LLV(VOL,13),1);
AA2:=VOL<REF(LLV(VOL,55),1);
AA3:=ABS(VOL-REF(VOL,1))/REF(VOL,1)<=0.06;
AA4:=VOL<=REF(V,1)*0.51 ;
AA5:=COUNT(CLOSE>REF(CLOSE,1),2)=2 AND COUNT(VOL<REF(VOL,1),2)=2;
STICKLINE(AA,0,V,2,0),COLORYELLOW;
STICKLINE(AAA,0,V,1,0),COLORMAGENTA;
STICKLINE(AA1,0,V,2,0),COLORMAGENTA;
STICKLINE(AA2,0,V,2,0),COLORRED;
STICKLINE(AA3,0,V,2,0),COLORWHITE;
STICKLINE(AA4,0,V,2,0),COLOR22A6E6;
STICKLINE(AA5,0,V,2,0),COLORGREEN;
地量:=VOL<=REF(LLV(VOL,13),1);
XG:=COUNT(地量>0,3)=3;
DRAWTEXT(XG ,VOL*0.5,'买'),COLORYELLOW;
VAR2:=1*AMOUNT;
三十日天量:=HHV(VAR2,30)=VAR2;
六十日天量:=HHV(VAR2,60)=VAR2;
百日天量:=HHV(VAR2,100)=VAR2;
一年天量:=HHV(VAR2,250)=VAR2;
STICKLINE(三十日天量,VOLUME,VOLUME*0.7,1,0),COLORMAGENTA;
DRAWTEXT(三十日天量,VOL*0.70,'----30'),COLORMAGENTA;
STICKLINE(六十日天量,VOLUME,VOLUME*0.7,1.5,0),COLORWHITE;
DRAWTEXT(六十日天量,VOL*0.8,'----60'),COLORWHITE;
STICKLINE(百日天量,VOLUME,VOLUME*0.7,1.5,0),COLORGREEN;
DRAWTEXT(百日天量,VOL*0.88,'----100'),COLORGREEN;
STICKLINE(一年天量,VOLUME,VOLUME*0.7,1,0),COLORRED;
DRAWTEXT(一年天量,VOL*1.0,'----250'),COLORRED;
获利盘:=WINNER(C)*100;
VARA2:=LLV(LOW,10);
VARA3:=HHV(HIGH,25);
动力线:= EMA((CLOSE-VARA2)/(VARA3-VARA2)*4,4);
BB5:=获利盘<=1;
STICKLINE(BB5,0,V,0.5,0),COLORBLUE;
四、成交量vol指标公式源码?
VAR1:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));
成交:=VOL,POINTDOT;
主动买盘:IF(CLOSE>OPEN,VAR1*(HIGH-LOW),IF(CLOSE<OPEN,VAR1*((HIGH- OPEN)+(CLOSE-LOW)),VOL/2)),COLORRED,POINTDOT;
主动卖盘:IF(CLOSE>OPEN,0-VAR1*((HIGH-CLOSE)+(OPEN- LOW)),IF(CLOSE<OPEN,0-VAR1*(HIGH-LOW),0-VOL/2)),COLOR00FF00,POINTDOT;
地量:=VOL<LLV(VOL,14)*1.001;
V2:=IF(CURRBARSCOUNT=1,VOL*240/FROMOPEN/REF(VOL,1)-1,VOL/REF(VOL,1)-1);
STICKLINE(VOL>0,VOL,0,3,1),COLORWHITE;
STICKLINE(主动买盘>V/2,0,V,2,0),COLORYELLOW;
STICKLINE(主动买盘<=V/2,0,V,2,0),COLORLIGRAY;
STICKLINE(主动买盘>0,0,主动买盘,2,0),COLORRED;
STICKLINE(主动卖盘<0,0,主动卖盘,2,0),COLOR00FF00;
STICKLINE(地量>0,0,VOL,1,0),COLORMAGENTA;
STICKLINE(V2>=1,V,0,1,0),COLORYELLOW;
五、黄金分割指标源码?
以下是通达信自动画黄金分割线主图源码{自动画黄金分割线}
{背景}
DRAWGBK(C>0, RGB(1,1,1),RGB(1,1,1),0,'0',0);
{K线色}
STICKLINE(CLOSE>OPEN,HIGH,LOW,0,0 ),COLOR0000C0;
STICKLINE(CLOSE>OPEN,OPEN,CLOSE,2.2,0 ),COLOR0000C0;
STICKLINE(CLOSE<OPEN,HIGH,LOW,0,0 ),COLOR00C000;
STICKLINE(CLOSE<OPEN,OPEN,CLOSE,2.2,0 ),COLOR00C000;
STICKLINE(CLOSE=OPEN,HIGH,LOW,0,0 ),COLORWHITE;
STICKLINE(CLOSE=OPEN,OPEN,CLOSE,2.2,0 ),COLORWHITE;
{自动画黄金分割线-源码}
N:=74;
M:=3;
PC:=(C+REF(C,1)+0)/3;
高:=REF(HHV(H,N),M);
低:=REF(LLV(L,N),M);
H19:=高-(高-低)*0.191;
H38:=高-(高-低)*0.382;
H中:=高-(高-低)*0.5;
H61:=高-(高-低)*0.618;
H80:=高-(高-低)*0.809;
顶点:REFDATE(高,DATE),COLORWHITE;
%19.8:REFDATE(H19,DATE),COLORYELLOW;
%38.2:REFDATE(H38,DATE),COLORMAGENTA;
%50:REFDATE(H中,DATE),COLORRED;
%61.8:REFDATE(H61,DATE),COLORMAGENTA;
%80.9:REFDATE(H80,DATE),COLORYELLOW;
低点:REFDATE(低,DATE),COLORWHITE;
DRAWTEXT(ISLASTBAR,顶点,'顶点'),COLORWHITE;
DRAWTEXT(ISLASTBAR,%19.8,'%19.8'),COLORYELLOW;
DRAWTEXT(I
六、黄金分割线指标源码?
股票技术分析中涉及到许多指标,黄金分割线就是其中一种。下面是黄金分割线指标的公式源码和计算过程:
黄金分割线 = (最高价 - 最低价)× 0.618 + 最低价
其中,最高价是指一定周期内的最高股价,最低价是指同一周期内的最低股价。黄金分割线指标是使用斐波那契数列中0.618这个比例来计算的。
在计算黄金分割线指标时,首先需要确定一个周期,也就是一段时间内的K线图。然后从该周期的最高价和最低价数据中进行计算。使用公式计算出黄金分割线后,该指标可以用于分析股票价格趋势,预测未来的价格变动方向。
需要注意的是,黄金分割线指标的计算方式可能会因不同的分析软件或服务商而略有不同。因此,在使用该指标进行交易决策之前,可以先了解所使用的软件或服务商的计算方法。
七、rsj指标源码?
rsi指标讲解的主要内容是基础的指标公式、买卖指标公式、精确买卖点、趋势分析、自用以及复合通道公式的解析,希望能够在实战中帮助到广大投资者。
//基础指标公式
50,DOTLINE;20;80;
DRAWBAND(80,RGB(0,30,255),100,RGB(0,30,255));
DRAWBAND(20,RGB(0,150,200),0,RGB(0,150,200));
DRAWTEXT_FIX(1,0.02,0,0,'★RSI6与RSA12金叉参考买入.死叉参考卖出. ★威廉WR大于80买入区.小于20卖出区.'),COLOR00FFFF,LINETHICK3;
CC:=FORCAST(C,3); HH:=FORCAST(H,3); LL:=FORCAST(L,3);
LC:=REF(WMA((2*CC+HH+LL)/4,3),1);
RSI6:SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100,COLORFF9900,LINETHICK0;
RSI12:SMA(MAX(CLOSE-LC,0),12,1)/SMA(ABS(CLOSE-LC),12,1)*100,COLOR00FFFF,LINETHICK0;
DRAWBAND(RSI6,RGB(255,80,0),RSI12,RGB(0,255,100));
SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100,COLORFF9900,LINETHICK3;
IF(RSI6>REF(RSI6,1),RSI6,DRAWNULL),COLOR0000FF,LINETHICK4;
SMA(MAX(CLOSE-LC,0),12,1)/SMA(ABS(CLOSE-LC),12,1)*100,COLOR00FFFF,LINETHICK2;
威廉WR:FORCAST(100*(HHV(HH,14)-CC)/(HHV(HH,14)-LLV(LL,14)),5),COLOR00FFFF,DOTLINE;
IF(威廉WR>80 ,威廉WR,DRAWNULL),COLOR00FF00,LINETHICK3;
IF(威廉WR<20,威廉WR,DRAWNULL),COLOR0000FF,LINETHICK3;
导入软件之后的基本走势图形有:
//买卖指标公式
N1:=6;
N2:=6;
N3:=6;
LC:=REF(CLOSE,1);
RSI1:SMA(MAX(CLOSE-LC,0),N1,1)/SMA(ABS(CLOSE-LC),N1,1)*100;
RSI2:SMA(MAX(CLOSE-LC,0),N2,1)/SMA(ABS(CLOSE-LC),N2,1)*100;
RSI3:SMA(MAX(CLOSE-LC,0),N3,1)/SMA(ABS(CLOSE-LC),N3,1)*100;
MA60:MA(C,60);
MA5:MA(C,5);
MA10:MA(C,10);
MA20:MA(C,20);
A:20;
D:80;
买:=RSI1<20 OR RSI1<80 AND C>REF(C,1)AND VOLREF(MA60,1) AND MA5>REF(MA5,1)AND MA10>REF(MA10,1)AND MA20>REF(MA20,1);
DRAWTEXT(买,RSI1*0.8,'买'),COLOR0099FF;
卖:=RSI1>80 AND VOL>REF(VOL,1);
DRAWTEXT(卖,RSI1*1.09,'卖'),COLOR0099FF;
//精确买卖点公式
LC := REF(CLOSE,1);
R:SMA(MAX(CLOSE-LC,0),9,1)/SMA(ABS(CLOSE-LC),9,1)*10;
K:=r-REF(r,1);
STICKLINE(k>REF(k,1) AND R<3 AND (k<0 OR REF(k,1)<0),3,5,2),colorred;
STICKLINE(k5.5,5,7,2),colorgreen;
x:=(k>REF(k,1) AND R<3.0 AND (k<0 OR REF(k,1)<0))*8;
y:=((k5.5)>0)*8;
//趋势分析
VAR1:=HHV(HIGH,33);
VAR2:=LLV(LOW,33);
A:=(SMA((CLOSE-VAR2)/(VAR1-VAR2),8,1))*(100),COLOR00FFFF;
价格线:EMA(HHV(A,3),1),colorgreen;
va1:=(CLOSE-LLV(LOW,90))/(HHV(HIGH,90)-LLV(LOW,90))*100;
va2:=SMA(va1,9,1),colorwhite;
趋势线:SMA(va2,6,1),colorff00ff;
va4:=3*va2-2*趋势线,colorff00ff;
撑压线:WMA((va2+趋势线+va4)/3,60),colorred;
LC:= REF(CLOSE,1);
RSI6:SMA(MAX(CLOSE-LC,0),6,1)/SMA(ABS(CLOSE-LC),6,1)*100,colorwhite;
RSI12:SMA(MAX(CLOSE-LC,0),12,1)/SMA(ABS(CLOSE-LC),12,1)*100,coloryellow;
卖线:85,LINETHICK02,POINTDOT,Color15FF15;
界线:50,LINETHICK02,POINTDOT,ColorFF1EFF;
买线:20,LINETHICK02,POINTDOT,Color28FFFF;
八、hcl指标源码?
HCL指标公式源码是针对特定目标设备设计的指标公式库。该库的目的是对设备运行状态进行实时检测,以便快速发现和解决设备问题。HCL指标公式源码包含各种指标公式,可以很快地集成到设备的监控系统中。在本文中,我们将深入讨论HCL指标公式源码的特点和优势。
九、dmi指标源码?
DMI指标又叫动向指标或趋向指标,其全称叫“Directional Movement Index,简称DMI”,也是由美国技术分析大师威尔斯·威尔德(Wells Wilder)所创造的,是一种中长期股市技术分析(Technical Analysis)方法。
DMI指标是通过分析股票价格在涨跌过程中买卖双方力量均衡点的变化情况,即多空双方的力量的变化受价格波动的影响而发生由均衡到失衡的循环过程,从而提供对趋势判断依据的一种技术指标。
dmi指标分类:DMI指标共有+DI(即PDI,下同)、-DI(即MDI,下同)、ADX、ADXR四条线,也是它的四个参数值,它分为多空指标(+DI、-DI)和趋向指标(ADX、ADXR)两组指标。
dmi指标公式源码
TR:=EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-ref(CLOSE,1))),ABS(ref(CLOSE,1)-LOW)),N);
HD:=HIGH-ref(HIGH,1);
LD:=ref(LOW,1)-LOW;
DMP:=EXPMEMA(IF(HD0&&HDLD,HD,0),N);
DMM:=EXPMEMA(IF(LD0&&LDHD,LD,0),N);
PDI:=DMP*100/TR,COLORFFFFFF;
DRAWTEXT_FIX(CO,0.01,0.9,0''),COLORRED;
DRAWTEXT_FIX(CO,1,1,0,''),COLORRED;
MDI:=DMM*100/TR,COLOR00FFFF;
ADX:=EXPMEMA(ABS(MDI-PDI)/(MDI+PDI)*100,M),COLOR0000FF,LINETHICK2;
ADXR:=EXPMEMA(ADX,M),COLOR00FF00,LINETHICK2;
DYNAINFO(9)0 AND CROSS(ADX,MDI) AND CROSS(ADXR,MDI) AND PDIMDI;
十、bias指标源码?
N:=12;
B:(CLOSE-MA(CLOSE,N))/MA(CLOSE,N)*100;
M:=INTPART(2*N/4);
A1:=REF(B,M)=HHV(B,2*M+1);
B1:=FILTER(A1,M);
C1:=BACKSET(B1,M+1);
D1:=FILTER(C1,M);
R3:=BACKSET(ISLASTBAR,BARSLAST(D1)+1); S1:=R3>REF(R3,1);
DRAWLINE(D1,B,S1,B,1),COLORRED;
M1:=INTPART(3*N/7);
A120:=REF(B,M1)=HHV(B,2*M1+1);
B120:=FILTER(A120,M1);
C321:=BACKSET(B120,M1+1);
D119:=FILTER(C321,M1);
R1:=BACKSET(ISLASTBAR,BARSLAST(D119)+1); S10:=R1>REF(R1,1);
DRAWLINE(D119,B,S10,B,1),COLORYELLOW;
M2:=INTPART(1*N/10);
A2:=REF(B,M2)=HHV(B,2*M2+1);
B2:=FILTER(A2,M2);
C2:=BACKSET(B2,M2+1);
D2:=FILTER(C2,M2);
R4:=BACKSET(ISLASTBAR,BARSLAST(D2)+1); S2:=R4>REF(R4,1);
DRAWLINE(D2,B,S2,B,1),COLORBLUE;