Ten hours of rash and the simplest market simulator is ready! Gracefully composes buy/sell commands list by trend events and perfectly calculates total return of fund, Sharpe ratio and other statistical parameters.
This is an example of a task it helps to accomplish:
If to define event as the stock price drops below $7.00, buy the same day 100 shares of the equity and sell them 5 days after (expecting recover), then what would be total return and the Sharpe ratio of the fund?
Data used is downloaded from Yahoo, for historical periods 2008 and 2009.
P.S. The code unexpectedly works faster than Python version of the same algorithm (on Pandas).