From 888f38ef1dff4fa9bde5ed0e7e7b502301c124fc Mon Sep 17 00:00:00 2001 From: Andreas Mueller Date: Sat, 15 Jul 2017 15:36:49 -0500 Subject: [PATCH] minor sphinx fixes --- doc/modules/model_evaluation.rst | 4 ---- doc/modules/multiclass.rst | 5 +++-- doc/whats_new.rst | 4 ++-- sklearn/multioutput.py | 8 +++----- 4 files changed, 8 insertions(+), 13 deletions(-) diff --git a/doc/modules/model_evaluation.rst b/doc/modules/model_evaluation.rst index 813a39339e848..d20716c528697 100644 --- a/doc/modules/model_evaluation.rst +++ b/doc/modules/model_evaluation.rst @@ -670,10 +670,6 @@ binary classification and multilabel indicator format. for an example of :func:`precision_recall_curve` usage to evaluate classifier output quality. - * See :ref:`sphx_glr_auto_examples_linear_model_plot_sparse_recovery.py` - for an example of :func:`precision_recall_curve` usage to select - features for sparse linear models. - Binary classification ^^^^^^^^^^^^^^^^^^^^^ diff --git a/doc/modules/multiclass.rst b/doc/modules/multiclass.rst index 5094372aca960..983fd416b5a05 100644 --- a/doc/modules/multiclass.rst +++ b/doc/modules/multiclass.rst @@ -353,7 +353,7 @@ Classifier Chain Classifier chains (see :class:`ClassifierChain`) are a way of combining a number of binary classifiers into a single multi-label model that is capable - of exploiting correlations among targets. +of exploiting correlations among targets. For a multi-label classification problem with N classes, N binary classifiers are assigned an integer between 0 and N-1. These integers @@ -373,5 +373,6 @@ typically many randomly ordered chains are fit and their predictions are averaged together. .. topic:: References: + Jesse Read, Bernhard Pfahringer, Geoff Holmes, Eibe Frank, - "Classifier Chains for Multi-label Classification", 2009. \ No newline at end of file + "Classifier Chains for Multi-label Classification", 2009. diff --git a/doc/whats_new.rst b/doc/whats_new.rst index 9f5a8f5c914ad..15fc44f60b4e4 100644 --- a/doc/whats_new.rst +++ b/doc/whats_new.rst @@ -4350,7 +4350,7 @@ Highlights - :ref:`out_of_bag` of generalization error for :ref:`ensemble` by `Andreas Müller`_. - - :ref:`randomized_l1`: Randomized sparse linear models for feature + - Randomized sparse linear models for feature selection, by `Alexandre Gramfort`_ and `Gael Varoquaux`_ - :ref:`label_propagation` for semi-supervised learning, by Clay @@ -4811,7 +4811,7 @@ Changelog `Mathieu Blondel`_ and `Lars Buitinck`_ - Documentation improvements: thumbnails in - :ref:`example gallery ` by `Fabian Pedregosa`_. + example gallery by `Fabian Pedregosa`_. - Important bugfixes in :ref:`svm` module (segfaults, bad performance) by `Fabian Pedregosa`_. diff --git a/sklearn/multioutput.py b/sklearn/multioutput.py index 6906d95869f2b..a84a6ce36b218 100644 --- a/sklearn/multioutput.py +++ b/sklearn/multioutput.py @@ -14,8 +14,6 @@ # # License: BSD 3 clause -from abc import ABCMeta - import numpy as np import scipy.sparse as sp from abc import ABCMeta, abstractmethod @@ -309,7 +307,7 @@ class MultiOutputClassifier(MultiOutputEstimator, ClassifierMixin): Attributes ---------- - estimators_ : list of `n_output` estimators + estimators_ : list of ``n_output`` estimators Estimators used for predictions. """ @@ -420,7 +418,7 @@ class ClassifierChain(BaseEstimator): Attributes ---------- classes_ : list - A list of arrays of length len(estimators_) containing the + A list of arrays of length ``len(estimators_)`` containing the class labels for each estimator in the chain. estimators_ : list @@ -456,7 +454,7 @@ def fit(self, X, Y): self : object Returns self. """ - X, Y = check_X_y(X, Y, multi_output=True, accept_sparse=True) + X, Y = check_X_y(X, Y, multi_output=True, accept_sparse=True) random_state = check_random_state(self.random_state) check_array(X, accept_sparse=True)