code: def do_bestfit(self):
          
          self.check_important_variables()
          self.fit_args = np.polyfit(
              self.args["x"], self.args["y"], self.args.get("degree", 1))
          self.done_bestfit = True
          return self.fit_args
docs: Method to get fit_args after getting necessary variables