Which function is responsible for what?
Some small comments for get_best_fit:
- undesirable call to plot within it. Bad sharing of responsibility / undocumented side effect / has to be called externally
- does not follow the best coding standards (arguments, comments etc)