8000 Correct PCA and RandomizedPCA docs related to whitening · raghavrv/scikit-learn@f5025c3 · GitHub
[go: up one dir, main page]

Skip to content

Commit f5025c3

Browse files
committed
Correct PCA and RandomizedPCA docs related to whitening
1 parent 323bcea commit f5025c3

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

sklearn/decomposition/pca.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -131,9 +131,9 @@ class PCA(BaseEstimator, TransformerMixin):
131131
use fit_transform(X) instead.
132132
133133
whiten : bool, optional
134-
When True (False by default) the `components_` vectors are divided
135-
by n_samples times singular values to ensure uncorrelated outputs
136-
with unit component-wise variances.
134+
When True (False by default) the `components_` vectors are multiplied
135+
by the square root of n_samples and then divided by the singular values
136+
to ensure uncorrelated outputs with unit component-wise variances.
137137
138138
Whitening will remove some information from the transformed signal
139139
(the relative variance scales of the components) but can sometime
@@ -504,9 +504,9 @@ class RandomizedPCA(BaseEstimator, TransformerMixin):
504504
.. versionchanged:: 0.18
505505
506506
whiten : bool, optional
507-
When True (False by default) the `components_` vectors are divided
508-
by the singular values to ensure uncorrelated outputs with unit
509-
component-wise variances.
507+
When True (False by default) the `components_` vectors are multiplied by
508+
the square root of (n_samples) and divided by the singular values to
509+
ensure uncorrelated outputs with unit component-wise variances.
510510
511511
Whitening will remove some information from the transformed signal
512512
(the relative variance scales of the components) but can sometime

0 commit comments

Comments
 (0)
0