

.. _sphx_glr_auto_examples_tree:

.. _tree_examples:

Decision Trees
--------------

Examples concerning the :mod:`sklearn.tree` module.



.. raw:: html

    <div class="sphx-glr-thumbnails">


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="A 1D regression with decision tree.">

.. only:: html

  .. image:: /auto_examples/tree/images/thumb/sphx_glr_plot_tree_regression_thumb.png
    :alt:

  :ref:`sphx_glr_auto_examples_tree_plot_tree_regression.py`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Decision Tree Regression</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="An example to illustrate multi-output regression with decision tree.">

.. only:: html

  .. image:: /auto_examples/tree/images/thumb/sphx_glr_plot_tree_regression_multioutput_thumb.png
    :alt:

  :ref:`sphx_glr_auto_examples_tree_plot_tree_regression_multioutput.py`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Multi-output Decision Tree Regression</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="Plot the decision surface of a decision tree trained on pairs of features of the iris dataset.">

.. only:: html

  .. image:: /auto_examples/tree/images/thumb/sphx_glr_plot_iris_dtc_thumb.png
    :alt:

  :ref:`sphx_glr_auto_examples_tree_plot_iris_dtc.py`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Plot the decision surface of decision trees trained on the iris dataset</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="The DecisionTreeClassifier provides parameters such as min_samples_leaf and max_depth to preven...">

.. only:: html

  .. image:: /auto_examples/tree/images/thumb/sphx_glr_plot_cost_complexity_pruning_thumb.png
    :alt:

  :ref:`sphx_glr_auto_examples_tree_plot_cost_complexity_pruning.py`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Post pruning decision trees with cost complexity pruning</div>
    </div>


.. raw:: html

    <div class="sphx-glr-thumbcontainer" tooltip="The decision tree structure can be analysed to gain further insight on the relation between the...">

.. only:: html

  .. image:: /auto_examples/tree/images/thumb/sphx_glr_plot_unveil_tree_structure_thumb.png
    :alt:

  :ref:`sphx_glr_auto_examples_tree_plot_unveil_tree_structure.py`

.. raw:: html

      <div class="sphx-glr-thumbnail-title">Understanding the decision tree structure</div>
    </div>


.. raw:: html

    </div>


.. toctree::
   :hidden:

   /auto_examples/tree/plot_tree_regression
   /auto_examples/tree/plot_tree_regression_multioutput
   /auto_examples/tree/plot_iris_dtc
   /auto_examples/tree/plot_cost_complexity_pruning
   /auto_examples/tree/plot_unveil_tree_structure

