@@ -604,7 +604,7 @@ class OrthogonalMatchingPursuit(MultiOutputMixin, RegressorMixin, LinearModel):
604604 Maximum norm of the residual. If not None, overrides n_nonzero_coefs.
605605
606606 fit_intercept : bool, default=True
607- whether to calculate the intercept for this model. If set
607+ Whether to calculate the intercept for this model. If set
608608 to false, no intercept will be used in calculations
609609 (i.e. data is expected to be centered).
610610
@@ -653,16 +653,18 @@ class OrthogonalMatchingPursuit(MultiOutputMixin, RegressorMixin, LinearModel):
653653
654654 .. versionadded:: 1.0
655655
656- Examples
656+ See Also
657657 --------
658- >>> from sklearn.linear_model import OrthogonalMatchingPursuit
659- >>> from sklearn.datasets import make_regression
660- >>> X, y = make_regression(noise=4, random_state=0)
661- >>> reg = OrthogonalMatchingPursuit(normalize=False).fit(X, y)
662- >>> reg.score(X, y)
663- 0.9991...
664- >>> reg.predict(X[:1,])
665- array([-78.3854...])
658+ orthogonal_mp : Solves n_targets Orthogonal Matching Pursuit problems.
659+ orthogonal_mp_gram : Solves n_targets Orthogonal Matching Pursuit
660+ problems using only the Gram matrix X.T * X and the product X.T * y.
661+ lars_path : Compute Least Angle Regression or Lasso path using LARS algorithm.
662+ Lars : Least Angle Regression model a.k.a. LAR.
663+ LassoLars : Lasso model fit with Least Angle Regression a.k.a. Lars.
664+ sklearn.decomposition.sparse_encode : Generic sparse coding.
665+ Each column of the result is the solution to a Lasso problem.
666+ OrthogonalMatchingPursuitCV : Cross-validated
667+ Orthogonal Matching Pursuit model (OMP).
666668
667669 Notes
668670 -----
@@ -676,15 +678,16 @@ class OrthogonalMatchingPursuit(MultiOutputMixin, RegressorMixin, LinearModel):
676678 Matching Pursuit Technical Report - CS Technion, April 2008.
677679 https://www.cs.technion.ac.il/~ronrubin/Publications/KSVD-OMP-v2.pdf
678680
679- See Also
681+ Examples
680682 --------
681- orthogonal_mp
682- orthogonal_mp_gram
683- lars_path
684- Lars
685- LassoLars
686- sklearn.decomposition.sparse_encode
687- OrthogonalMatchingPursuitCV
683+ >>> from sklearn.linear_model import OrthogonalMatchingPursuit
684+ >>> from sklearn.datasets import make_regression
685+ >>> X, y = make_regression(noise=4, random_state=0)
686+ >>> reg = OrthogonalMatchingPursuit(normalize=False).fit(X, y)
687+ >>> reg.score(X, y)
688+ 0.9991...
689+ >>> reg.predict(X[:1,])
690+ array([-78.3854...])
688691 """
689692
690693 def __init__ (
@@ -711,13 +714,12 @@ def fit(self, X, y):
711714 Training data.
712715
713716 y : array-like of shape (n_samples,) or (n_samples, n_targets)
714- Target values. Will be cast to X's dtype if necessary
715-
717+ Target values. Will be cast to X's dtype if necessary.
716718
717719 Returns
718720 -------
719721 self : object
720- returns an instance of self.
722+ Returns an instance of self.
721723 """
722724 _normalize = _deprecate_normalize (
723725 self .normalize , default = True , estimator_name = self .__class__ .__name__
0 commit comments