量价时空公式 指标 源码[其他软件公式]
指标代码分析及使用参考建议:
该指标是一个量价时空指标,根据给定的公式计算出一系列数值,并在K线图上进行相应的绘制和填充。具体的思路和操作建议如下:
首先,根据输入的参数计算出一些常用的指标,例如总的K线数量、前一日收盘价、最高价与最低价之差的十分之一等。
然后,根据上述指标计算出一系列的累加变量,即c1、c2、c3等,它们表示当前收盘价是否落入相应的价位范围内,并与之前的条件进行判断。
接着,根据累加变量的求和结果,将其转换为对应的数值,并计算出最大值。
根据以上计算得到的数值,绘制出相应的填充区域,以突出显示在特定条件下的数值变化。
在主图上绘制出成交量柱状图,并根据收盘价与开盘价的大小关系,使用不同的颜色进行标注。
在主图上绘制出黄金分割线,即从最低价到最高价的区间按照黄金分割比例进行划分,以便观察价格的变化趋势。
基于最低价的移动平均线以及相应比例的标准差,绘制出一系列斜率趋势线,用于指导买入和卖出的时机。
最后,在图表上绘制出特定条件下的时间点,以便于观察市场波动的时间规律。
综上所述,根据该指标的计算和绘制结果,可以分析市场的量价关系和时间规律,提供买入和卖出的操作建议。但需要注意的是,以上仅为一种分析思路,具体操作建议还需结合其他技术指标和市场状况进行综合考虑。
源码:
{量价时空}INPUT:N(5);
a0:=BARSCOUNT(c);a3:=SYSPARAM(3);a2:=SYSPARAM(2);
a4:=SYSPARAM(4);a5:=SYSPARAM(5);
nn0:=a3-a2;nn:=a0-a2;hh1:=(a4-a5)/10;
y0:=a0>=a2;vv0:=if(y0=1 and SYSPARAM(1)>=a0,v,0);
c1:=if(BETWEEN(c,a4-0*hh1,a4-1*hh1),vv0,0);
c2:=if(BETWEEN(c,a4-1*hh1,a4-2*hh1),vv0,0);
c3:=if(BETWEEN(c,a4-2*hh1,a4-3*hh1),vv0,0);
c4:=if(BETWEEN(c,a4-3*hh1,a4-4*hh1),vv0,0);
c5:=if(BETWEEN(c,a4-4*hh1,a4-5*hh1),vv0,0);
c6:=if(BETWEEN(c,a4-5*hh1,a4-6*hh1),vv0,0);
c7:=if(BETWEEN(c,a4-6*hh1,a4-7*hh1),vv0,0);
c8:=if(BETWEEN(c,a4-7*hh1,a4-8*hh1),vv0,0);
c9:=if(BETWEEN(c,a4-8*hh1,a4-9*hh1),vv0,0);
c10:=if(BETWEEN(c,a4-9*hh1,a4-10*hh1),vv0,0);
v1:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c1,nn0),0),2));
v2:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c2,nn0),0),2));
v3:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c3,nn0),0),2));
v4:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c4,nn0),0),2));
v5:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c5,nn0),0),2));
v6:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c6,nn0),0),2));
v7:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c7,nn0),0),2));
v8:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c8,nn0),0),2));
v9:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c9,nn0),0),2));
v10:=STRTONUM(NUMTOSTR(if(ISLASTBAR,sum(c10,nn0),0),2));
av0:=max(v1,max(v2,max(v3,max(v4,max(v5,max(v6,max(v7,max(v8,max(v9,v10)))))))));
FILLRGN(v1/av0>=nn/nn0 and nn>=0,a4-0*hh1,a4-1*hh1+0.05),Color008080;
FILLRGN(v2/av0>=nn/nn0 and nn>=0,a4-1*hh1,a4-2*hh1+0.05),Color008080;
FILLRGN(v3/av0>=nn/nn0 and nn>=0,a4-2*hh1,a4-3*hh1+0.05),Color008080;
FILLRGN(v4/av0>=nn/nn0 and nn>=0,a4-3*hh1,a4-4*hh1+0.05),Color008080;
FILLRGN(v5/av0>=nn/nn0 and nn>=0,a4-4*hh1,a4-5*hh1+0.05),Color008080;
FILLRGN(v6/av0>=nn/nn0 and nn>=0,a4-5*hh1,a4-6*hh1+0.05),Color008080;
FILLRGN(v7/av0>=nn/nn0 and nn>=0,a4-6*hh1,a4-7*hh1+0.05),Color008080;
FILLRGN(v8/av0>=nn/nn0 and nn>=0,a4-7*hh1,a4-8*hh1+0.05),Color008080;
FILLRGN(v9/av0>=nn/nn0 and nn>=0,a4-8*hh1,a4-9*hh1+0.05),Color008080;
FILLRGN(v10/av0>=nn/nn0 and nn>=0,a4-9*hh1,a4-10*hh1+0.05),Color008080{,colormagenta};hh:=SYSPARAM(4);ll:=SYSPARAM(5);
x:=ll-(hh-ll+MINDIFF)/n;
y:=HHV(VOL,SYSPARAM(3)-SYSPARAM(2)+1);
yvb:=y[SYSPARAM(3)]/(ll-x+MINDIFF);
z:=VOL/yvb+x;
STICKLINE(CLOSE>REF(CLOSE,1),x,z,7,1),Color0000FF;
STICKLINE(CLOSE<=REF(CLOSE,1),x,z,7,0),ColorEAE000;
五日:MA(z,5);
十日:MA(z,10);DRAWTEXT(BARPOS=SYSPARAM(2),HIGH,{STKNAME+'\n'+STKLABEL+'\n'+}BLKNAME)align4,COLORGREEN;{http://www.cxh99.com}
STICKLINE(C>=O,C,O,7,0),COLORRED;
STICKLINE(C>=O,C,O,4,0),COLORB0B0FF;
STICKLINE(C>=O,C,O,2,0),COLORYELLOW;
STICKLINE(C>=O,H,L,0,0),COLORYELLOW;
STICKLINE(C<=O,C,O,7,0),COLORFF2020;
STICKLINE(C<=O,C,O,4,0),COLORFF6600;
STICKLINE(C<=O,C,O,2,0),COLORCYAN;
STICKLINE(C<=O,H,L,0,0),COLORCYAN;
博弈线:=WMA(CLOSE,8),linethick3;
byx:=WMA(CLOSE,8),linethick3;
FILLRGN(byx>ref(byx,1),byx,ref(byx,1)),COLORRED;
{FILLRGN(byx }CXH1:=SYSPARAM(3)-SYSPARAM(2)+1;
CXH2:=SYSPARAM(3)-BARPOS;
CXH3:=HHV(HIGH,CXH1);
CXH4:=LLV(LOW,CXH1);
CXH5:=REFX(CXH3,CXH2); //主图最高价
CXH5:IF(SYSPARAM(3)<>SYSPARAM(1),SYSPARAM(6),CXH5),COLORRED,POINTDOT;
CXH6:REFX(CXH4,CXH2),COLORWHITE,POINTDOT; //主图最低价
黄191: (CXH5-CXH6)*0.191+CXH6,COLORYELLOW,POINTDOT;
黄382: (CXH5-CXH6)*0.382+CXH6,COLORYELLOW,POINTDOT;
黄500: (CXH5-CXH6)*0.500+CXH6,COLORGREEN,POINTDOT;
黄618: (CXH5-CXH6)*0.618+CXH6,COLORYELLOW,POINTDOT;
黄809: (CXH5-CXH6)*0.809+CXH6,COLORYELLOW,POINTDOT;
A:=LOW=LLV(LOW,240);
A1:=BARSLAST(A);
VERTLINE(A1=30);
VERTLINE(A1=60);
VERTLINE(A1=90);
VERTLINE(A1=120);
VERTLINE(A1=150);
VERTLINE(A1=180);
VERTLINE(A1=210);
VERTLINE(A1=2400);
DRAWTEXT(A1=30,HIGH,'第一时间');
DRAWTEXT(A1=60,HIGH,'第二时间');
DRAWTEXT(A1=90,HIGH,'第三时间');
DRAWTEXT(A1=120,HIGH,'第四时间');
DRAWTEXT(A1=150,HIGH,'第五时间');
DRAWTEXT(A1=180,HIGH,'第六时间');
DRAWTEXT(A1=210,HIGH,'第七时间');
DRAWTEXT(A1=240,HIGH,'第八时间');
CXHr1:=SMA(MAX(CLOSE-REF(CLOSE,1),0),6,1)/SMA(ABS(CLOSE-REF(CLOSE,1)),6,1)*100;
DRAWICON(CROSS(82,CXHr1),HIGH+0.108,2);VERTLINE(CROSS(82,CXHr1)),POINTDOT;
DRAWSL(CROSS(82,CXHr1),HHV(HIGH,1),0,8,1),colormagenta,POINTDOT;
b1:=(SYSPARAM(4)-SYSPARAM(5))/(SYSPARAM(3)-SYSPARAM(2));
DRAWSL(BARPOS=SYSPARAM(1),LOW,378*b1/100,0,0),COLORwhite,POINTDOT;
DRAWSL(BARPOS=SYSPARAM(1),LOW,188*b1/100,0,0),COLORwhite,POINTDOT;
DRAWSL(BARPOS=SYSPARAM(1),LOW,141*b1/100,0,0),COLORwhite,POINTDOT;
DRAWSL(BARPOS=SYSPARAM(1),LOW,95*b1/100,0,0),COLORwhite,POINTDOT;
DRAWSL(BARPOS=SYSPARAM(1),LOW,48*b1/100,0,0),COLORgreen,;
DRAWSL(BARPOS=SYSPARAM(1),LOW,24.5*b1/100,0,0),COLORwhite,POINTDOT;
DRAWSL(BARPOS=SYSPARAM(1),LOW,16.5*b1/100,0,0),COLORwhite,POINTDOT;
DRAWSL(BARPOS=SYSPARAM(1),LOW,13*b1/100,0,0),COLORwhite,POINTDOT;
DRAWSL(BARPOS=SYSPARAM(1),LOW,7*b1/100,0,0),COLORwhite,POINTDOT;
{程序化交易 www.cxh99.com }
公式导入教程: 【通达信公式源码导入方法教程】 【同花顺公式源码导入方法教程】 【大智慧新一代公式源码导入方法教程】
有思路,想编写各种指标公式,交易模型,选股公式,还原公式的朋友
可联系技术人员 QQ: 262069696 或微信:cxhjy888 进行 有偿收费 编写!(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)
(注:由于人数限制,QQ或微信请选择方便的一个联系我们就行,加好友时请简单备注下您的需求,否则无法通过。谢谢您!)
相关文章
-
没有相关内容