function bugFunctions with parameters do not work correctly: the returned value is sometimes different from the expected one.
The example script works correctly only when idx = 1 (instead of the current line 6).
Function
[RS]Function Account Margin Call Functions V0some simple functions to handle account margin call / trailling stop for account.
[RS]Function Martingale Multiplier - MA Crossover Bias V1EXPERIMENTAL:
WARNING: Martingale is subject to HUGE drawdown spikes, use at your own risk!
updated function to also double(aply multiplier) on even trades, example with a MA's crossover.