Modified purge to change order whenever the sell price changes.
Adds lower and upper limits to rising_peak and falling_trench respectively to keep the limit within a factor of the extreme prices.
Modifies redis_client to deal with the same.
Modifies extract scripts to cover a larger window of samples and to use the database correctly using imports.