I am fresh new with Zorro. I have developed my very first strategy and seems to work fine, it opens pending orders and updates Trailing Stops correctly.
But I am trying now optimization.
I have set this at the beginning of the script:

set(PARAMETERS);
BarPeriod = 1440;
//...
var sl = optimize(1,0.1,1,0.1) * diff;

And when I click in Train, after some time an error popup emerges saying "Crash in script" and this message is shown in the logs window:
"Parameter 1 step 1: 0.10 => 0.34 52/579"

Any clue why this happens?

Thanks, Zorro is a great tool!