R programming for backtesting