|
|
发表于 2014-7-10 23:50:09
|
显示全部楼层
本帖最后由 digit 于 2014-7-11 00:16 编辑
这是收费指标,可以用就可以了
[mw_shl_code=cpp,true]#property indicator_separate_window
#property indicator_buffers 2
#property indicator_color1 Magenta
#property indicator_color2 DimGray
#property indicator_width1 2
#property indicator_width2 1
#property indicator_minimum 0
#property indicator_maximum 100
#property indicator_level1 25
#property indicator_level2 75
#property indicator_levelcolor DimGray
extern int pstLength = 9;
extern int pstX = 5;
extern int pstSmooth = 3;
extern int smoothPeriod = 10;
extern int smoothPhase = 100;
double pstBuffer[];
double pssBuffer[];
double wrkBuffer[][5];
double trend[];
int init()
{
IndicatorBuffers(3);
SetIndexBuffer(0,pstBuffer); SetIndexLabel(0,"Stochastic");
SetIndexBuffer(1,pssBuffer); SetIndexLabel(1,"Signal");
SetIndexBuffer(2,trend);
.
.
.
.
.
int start()
{
.
.
.
.
.
if (max>0)
wrkBuffer[r][TripleK] = 100.0*(Close-min)/max;
else wrkBuffer[r][TripleK] = 0.0;
if (i==(Bars-1))
{
wrkBuffer[r][TripleDF] = wrkBuffer[r][TripleK];
wrkBuffer[r][TripleDS] = wrkBuffer[r][TripleK];
continue;
}
.
.
.
.
.
.[/mw_shl_code]
|
评分
-
查看全部评分
|