(self, X, y)
return self
A reference implementation of a fitting function for a classifier.

        Parameters
        ----------
        X : array-like, shape (n_samples, n_features)
            The training input samples.
        y : array-like, shape (n_samples,)
            The target values. An array of int.

        Returns
        -------
        self : object
            Returns self.
A reference implementation of a fitting function for a classifier.
A reference implementation of a fitting function for a classifier .
def fit(self, X, y):
        """A reference implementation of a fitting function for a classifier.

        Parameters
        ----------
        X : array-like, shape (n_samples, n_features)
            The training input samples.
        y : array-like, shape (n_samples,)
            The target values. An array of int.

        Returns
        -------
        self : object
            Returns self.
        """
        # Check that X and y have correct shape
        X, y = check_X_y(X, y)
        # Store the classes seen during fit
        self.classes_ = unique_labels(y)

        self.X_ = X
        self.y_ = y
        # Return the classifier
        return self
def fit ( self , X , y ) : # Check that X and y have correct shape X , y = check_X_y ( X , y ) # Store the classes seen during fit self . classes_ = unique_labels ( y ) self . X_ = X self . y_ = y # Return the classifier return self