def eval_poly(self, poly: Polynomial): error = sqrt( sum([(float(dp[1]) - poly.calculate(float(dp[0])))**2 for dp in self.data])) return error