<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def bestfit_func(self, bestfit_x):
 """ Returns y value """

        if not self.bestfit_func:
            raise KeyError("Do do_bestfit first")
        return self.args["func"](self.fit_args, bestfit_x)