8000 Use deprecated sphinx syntax for SparsePCA docs · scikit-learn/scikit-learn@732c46c · GitHub
[go: up one dir, main page]

Skip to content

Commit 732c46c

Browse files
committed
Use deprecated sphinx syntax for SparsePCA docs
1 parent fe539bc commit 732c46c

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

sklearn/decomposition/sparse_pca.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
# Author: Vlad Niculae, Gael Varoquaux, Alexandre Gramfort
33
# License: BSD 3 clause
44

5+
import warnings
6+
57
import numpy as np
68

79
from ..utils import check_random_state, check_array
@@ -10,8 +12,6 @@
1012
from ..base import BaseEstimator, TransformerMixin
1113
from .dict_learning import dict_learning, dict_learning_online
1214

13-
import warnings
14-
1515

1616
class SparsePCA(BaseEstimator, TransformerMixin):
1717
"""Sparse Principal Components Analysis (SparsePCA)
@@ -150,8 +150,11 @@ def transform(self, X, ridge_alpha=None):
150150
151151
ridge_alpha: float, default: 0.01
152152
Amount of ridge shrinkage to apply in order to improve
153-
conditioning. Note that as of 0.19 this parameter is deprecated and
154-
should be specified in the constructor.
153+
conditioning.
154+
155+
.. deprecated:: 0.19
156+
This parameter will be removed in 0.21.
157+
Specify `ridge_alpha` in the `SparsePCA` constructor.
155158
156159
Returns
157160
-------

0 commit comments

Comments
 (0)
0