con 为什么 会一直显示为1
Vars //此处添加变量 Series<Numeric> con;OnInit() { con=0; }OnBar(ArrayRef<Integer> indexs) { if (longshort[1]> 50+boLength1 and MarketPosition == 0) { SellShort(0,open); con = 1; } Commentary(\"con指标:\"+text(con) ); }为什么以上代码在运行时 并没有满足建仓条件 CON指标就显示为1而变成下面这样 就会显示为0Vars //此处添加变量 Series<Numeric> con;OnInit() { con=0; }OnBar(ArrayRef<Integer> indexs) { if (longshort[1]> 50+boLength1 and MarketPosition == 0) { SellShort(0,open); //con = 1; } Commentary(\"con指标:\"+text(con) ); }