I have been constantly re-writing the same code to do a quick Simple Moving Average Crossover (SMAC) analysis of a stock price for too long.
I've written this to produce either a SMAC dataset or a plot showing a simple implementation of this trading strategy.