Refactor log_example to be in a class and delete simple_log_example because of code duplication with simple_linear_example