forex margin call & closeout calculator backtesting trading strategies in r