Strange behavior in the newest version:

Code:
vars smth1=series(Smooth(Close,12*20));
if(smth1[1]>Close[0]){
    smth1[0]=Smooth(Close,6*20);
}



as well as

Code:
vars smth1=series(1.);
smth1[0]=Smooth(Close,12*20);
if(smth1[1]>Close[0]){
    smth1[0]=Smooth(Close,6*20);
}



gives the error 041: Inconsistent series.

While

Code:
vars smth1=series(1.);
if(smth1[1]>Close[0]){
    smth1[0]=Smooth(Close,6*20);
}else{
    smth1[0]=Smooth(Close,12*20);
}



works just fine.

In all cases above I do not see what could possibly make the series inconsistent, since it is always advanced at a fixed location within a run().

Last edited by Hredot; 01/04/18 15:37.