Hi, bellow is the money management script suggested in the documentation:

Code
// multi-asset system: reinvest the square root of profits separately per component and long / short trades
var AvailableCapital = Capital/sqrt(NumComponents);
Margin = ifelse(ForLongTrade,OptimalFLong,OptimalFShort)*AvailableCapital*sqrt(1+(WinLong-LossLong)/AvailableCapital);


So if OptimalFLong = 0, Margin for long trades is 0. But how OptimalFLong is effecting the training process? For example NumWFOCycles=3 and if in the first training loop long trades loose money. In this case, OptimalFLong< 0 right? Then in the following loops, there will be no long orders any more?

What if short trades also loose money, then their will be no trades at all?