A technical q trader on SPY given macd.
python teststratgy.py
QLearner.py: an independent tabular (dyna)q-learner.
StrategyLearner.py: Build upon Qlearner.py to learn the trading strategy
testStrategy.py: train and test the StrategyLearner
util.py: some helper functions for the model
please see this link