Trend-Following Trading System, Quantitative Trading in Python