code: def predict_mu(self, X):
          
          if not self._is_fitted:
              raise AttributeError('GAM has not been fitted. Call fit first.')
  
          X = check_X(X, n_feats=self.statistics_['m_features'],
                      edge_knots=self.edge_knots_, dtypes=self.dtype,
                      features=self.feature, verbose=self.verbose)
  
          lp = self._linear_predictor(X)
          return self.link.mu(lp, self.distribution)
docs: preduct expected value of target given model and input X
  
          Parameters
          ---------
          X : array-like of shape (n_samples, m_features),
              containing the input dataset
  
          Returns
          -------
          y : np.array of shape (n_samples,)
              containing expected values under the model