Tidy up and added a new Median Filter