多周期里,比如15min和30min两个周期,历史bar的运行机制是怎样的?一根30min的bar包含两根15min的bar,是否同一根30min的bar会运行两次?
虽然你加载了2个品种
也要看你的代码是不是涉及多图层的
然后在这种情况下,是会运行2次。
Vars
Global Numeric a;
Events
OnInit()
{
a=0;
}
OnBar(ArrayRef<Integer> indexs)
{
range[0:1]
{
Commentary("a="+text(a));
a=a+1;
}
}