Skip to content

Commit fb123ed

Browse files
committed
More doc fixes. Latex builds again.
1 parent a05bc8d commit fb123ed

File tree

22 files changed

+368
-151
lines changed

22 files changed

+368
-151
lines changed

doc/datasets/index.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,20 @@ features::
255255
_`Faster API-compatible implementation`: https://github.com/mblondel/svmlight-loader
256256

257257

258+
.. make sure everything is in a toc tree
259+
260+
.. toctree::
261+
:maxdepth: 2
262+
:hidden:
263+
264+
olivetti_faces
265+
twenty_newsgroups
266+
mldata
267+
labeled_faces
268+
covtype
269+
rcv1
270+
271+
258272
.. include:: olivetti_faces.rst
259273

260274
.. include:: twenty_newsgroups.rst

doc/modules/clustering.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Clustering
55
==========
66

7-
`Clustering <https://en.wikipedia.org/wiki/Cluster_analysis>`_ of
7+
`Clustering <https://en.wikipedia.org/wiki/Cluster_analysis>`__ of
88
unlabeled data can be performed with the module :mod:`sklearn.cluster`.
99

1010
Each clustering algorithm comes in two variants: a class, that implements

doc/whats_new.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ Enhancements
235235

236236
- The "Wisconsin Breast Cancer" classical two-class classification dataset
237237
is now included in scikit-learn, available with
238-
:fun:`sklearn.dataset.load_breast_cancer`.
238+
:func:`sklearn.dataset.load_breast_cancer`.
239239

240240
- Upgraded to joblib 0.9.3 to benefit from the new automatic batching of
241241
short tasks. This makes it possible for scikit-learn to benefit from

examples/applications/face_recognition.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
1111
.. _LFW: http://vis-www.cs.umass.edu/lfw/
1212
13-
Expected results for the top 5 most represented people in the dataset::
13+
Expected results for the top 5 most represented people in the dataset:
1414
1515
================== ============ ======= ========== =======
1616
precision recall f1-score support

examples/ensemble/plot_partial_dependence.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
Partial Dependence Plots
44
========================
55
6-
Partial dependence plots show the dependence between the target function [1]_
6+
Partial dependence plots show the dependence between the target function [2]_
77
and a set of 'target' features, marginalizing over the
88
values of all other features (the complement features). Due to the limits
99
of human perception the size of the target feature set must be small (usually,
@@ -13,7 +13,7 @@
1313
1414
This example shows how to obtain partial dependence plots from a
1515
:class:`~sklearn.ensemble.GradientBoostingRegressor` trained on the California
16-
housing dataset. The example is taken from [HTF2009]_.
16+
housing dataset. The example is taken from [1]_.
1717
1818
The plot shows four one-way and one two-way partial dependence plots.
1919
The target variables for the one-way PDP are:
@@ -38,10 +38,10 @@
3838
of the house age, whereas for values less than two there is a strong dependence
3939
on age.
4040
41-
.. [HTF2009] T. Hastie, R. Tibshirani and J. Friedman,
41+
.. [1] T. Hastie, R. Tibshirani and J. Friedman,
4242
"Elements of Statistical Learning Ed. 2", Springer, 2009.
4343
44-
.. [1] For classification you can think of it as the regression score before
44+
.. [2] For classification you can think of it as the regression score before
4545
the link function.
4646
"""
4747
print(__doc__)

sklearn/calibration.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -46,20 +46,21 @@ class CalibratedClassifierCV(BaseEstimator, ClassifierMixin):
4646
to offer more accurate predict_proba outputs. If cv=prefit, the
4747
classifier must have been fit already on data.
4848
49-
method : 'sigmoid' | 'isotonic'
49+
method : 'sigmoid' or 'isotonic'
5050
The method to use for calibration. Can be 'sigmoid' which
5151
corresponds to Platt's method or 'isotonic' which is a
5252
non-parameteric approach. It is not advised to use isotonic calibration
53-
with too few calibration samples (<<1000) since it tends to overfit.
53+
with too few calibration samples ``(<<1000)`` since it tends to overfit.
5454
Use sigmoids (Platt's calibration) in this case.
5555
56-
cv : integer/cross-validation generator/iterable or "prefit", optional
56+
cv : integer, cross-validation generator, iterable or "prefit", optional
5757
Determines the cross-validation splitting strategy.
5858
Possible inputs for cv are:
59-
- None, to use the default 3-fold cross-validation,
60-
- integer, to specify the number of folds.
61-
- An object to be used as a cross-validation generator.
62-
- An iterable yielding train/test splits.
59+
60+
- None, to use the default 3-fold cross-validation,
61+
- integer, to specify the number of folds.
62+
- An object to be used as a cross-validation generator.
63+
- An iterable yielding train/test splits.
6364
6465
For integer/None inputs, if ``y`` is binary or multiclass,
6566
:class:`StratifiedKFold` used. If ``y`` is neither binary nor

sklearn/covariance/graph_lasso_.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -468,10 +468,11 @@ class GraphLassoCV(GraphLasso):
468468
cv : int, cross-validation generator or an iterable, optional
469469
Determines the cross-validation splitting strategy.
470470
Possible inputs for cv are:
471-
- None, to use the default 3-fold cross-validation,
472-
- integer, to specify the number of folds.
473-
- An object to be used as a cross-validation generator.
474-
- An iterable yielding train/test splits.
471+
472+
- None, to use the default 3-fold cross-validation,
473+
- integer, to specify the number of folds.
474+
- An object to be used as a cross-validation generator.
475+
- An iterable yielding train/test splits.
475476
476477
For integer/None inputs :class:`KFold` is used.
477478

sklearn/cross_validation.py

Lines changed: 24 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1089,7 +1089,7 @@ def __len__(self):
10891089

10901090

10911091
class LabelShuffleSplit(ShuffleSplit):
1092-
'''Shuffle-Labels-Out cross-validation iterator
1092+
"""Shuffle-Labels-Out cross-validation iterator
10931093
10941094
Provides randomized train/test indices to split data according to a
10951095
third-party provided label. This label information can be used to encode
@@ -1118,7 +1118,7 @@ class LabelShuffleSplit(ShuffleSplit):
11181118
Labels of samples
11191119
11201120
n_iter : int (default 5)
1121-
Number of re-shuffling & splitting iterations.
1121+
Number of re-shuffling and splitting iterations.
11221122
11231123
test_size : float (default 0.2), int, or None
11241124
If float, should be between 0.0 and 1.0 and represent the
@@ -1134,7 +1134,8 @@ class LabelShuffleSplit(ShuffleSplit):
11341134
11351135
random_state : int or RandomState
11361136
Pseudo-random number generator state used for random sampling.
1137-
'''
1137+
1138+
"""
11381139
def __init__(self, labels, n_iter=5, test_size=0.2, train_size=None,
11391140
random_state=None):
11401141

@@ -1208,10 +1209,11 @@ def cross_val_predict(estimator, X, y=None, cv=None, n_jobs=1,
12081209
cv : int, cross-validation generator or an iterable, optional
12091210
Determines the cross-validation splitting strategy.
12101211
Possible inputs for cv are:
1211-
- None, to use the default 3-fold cross-validation,
1212-
- integer, to specify the number of folds.
1213-
- An object to be used as a cross-validation generator.
1214-
- An iterable yielding train/test splits.
1212+
1213+
- None, to use the default 3-fold cross-validation,
1214+
- integer, to specify the number of folds.
1215+
- An object to be used as a cross-validation generator.
1216+
- An iterable yielding train/test splits.
12151217
12161218
For integer/None inputs, if ``y`` is binary or multiclass,
12171219
:class:`StratifiedKFold` used. If the estimator is a classifier
@@ -1382,10 +1384,11 @@ def cross_val_score(estimator, X, y=None, scoring=None, cv=None, n_jobs=1,
13821384
cv : int, cross-validation generator or an iterable, optional
13831385
Determines the cross-validation splitting strategy.
13841386
Possible inputs for cv are:
1385-
- None, to use the default 3-fold cross-validation,
1386-
- integer, to specify the number of folds.
1387-
- An object to be used as a cross-validation generator.
1388-
- An iterable yielding train/test splits.
1387+
1388+
- None, to use the default 3-fold cross-validation,
1389+
- integer, to specify the number of folds.
1390+
- An object to be used as a cross-validation generator.
1391+
- An iterable yielding train/test splits.
13891392
13901393
For integer/None inputs, if ``y`` is binary or multiclass,
13911394
:class:`StratifiedKFold` used. If the estimator is a classifier
@@ -1643,10 +1646,11 @@ def check_cv(cv, X=None, y=None, classifier=False):
16431646
cv : int, cross-validation generator or an iterable, optional
16441647
Determines the cross-validation splitting strategy.
16451648
Possible inputs for cv are:
1646-
- None, to use the default 3-fold cross-validation,
1647-
- integer, to specify the number of folds.
1648-
- An object to be used as a cross-validation generator.
1649-
- An iterable yielding train/test splits.
1649+
1650+
- None, to use the default 3-fold cross-validation,
1651+
- integer, to specify the number of folds.
1652+
- An object to be used as a cross-validation generator.
1653+
- An iterable yielding train/test splits.
16501654
16511655
For integer/None inputs, if ``y`` is binary or multiclass,
16521656
:class:`StratifiedKFold` used. If the estimator is a classifier
@@ -1716,10 +1720,11 @@ def permutation_test_score(estimator, X, y, cv=None,
17161720
cv : int, cross-validation generator or an iterable, optional
17171721
Determines the cross-validation splitting strategy.
17181722
Possible inputs for cv are:
1719-
- None, to use the default 3-fold cross-validation,
1720-
- integer, to specify the number of folds.
1721-
- An object to be used as a cross-validation generator.
1722-
- An iterable yielding train/test splits.
1723+
1724+
- None, to use the default 3-fold cross-validation,
1725+
- integer, to specify the number of folds.
1726+
- An object to be used as a cross-validation generator.
1727+
- An iterable yielding train/test splits.
17231728
17241729
For integer/None inputs, if ``y`` is binary or multiclass,
17251730
:class:`StratifiedKFold` used. If the estimator is a classifier

0 commit comments

Comments
 (0)