老师看一下这一段是什么意思?
// Commentary("amphigh="+text(amphigh));// Commentary("amplow="+text(amplow));
PlotNumeric("jjx", dayavg);
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
if ((time<0.20 and time>=0.21) or (((time>0.13 and time<=0.15) or time<0.08 or time>=0.2230) and time>=0.09 and time<0.10) or (time<0.12 and time>=0.1330)) {
barnum = 1;
if (close>open) {upspeed = (high-low)/low*100; dnspeed =(high-close)/high*100;}
else if (close<open){dnspeed = (high-low)/high*100; upspeed =(close-low)/low*100;}
else {dnspeed = (high-low)/high*100; upspeed = (high-low)/low*100;}
if ((time>0.1400 and time<=0.1500 and (time<=0.1000 or time>=0.2100))) {muspeed = upspeed; mdspeed = dnspeed;}
usdis = 0; dsdis = 0; hipoint = 0; lopoint = 0; tnum = Mod(value(left(text(n), 4)),50)-2; 老师主要是这一行代码,是什么意思呢?
} else {
barnum = barnum + 1;
}
// Commentary("barnum="+text(barnum)); 这一行是对5个变量进行了赋值 ,其中前面四个变量都赋值 为0.
最后一个变量有一定的计算结算进行赋值,具体的可以看一下帮助文档里,mod,value,left,text等几个函数的用法。
页:
[1]