Added CSV support (sort of) and an average time spent function.