.. only:: html
.. note::
:class: sphx-glr-download-link-note
Click :ref:`here ` to download the full example code
.. rst-class:: sphx-glr-example-title
.. _sphx_glr_auto_data_analysis_graphics_plot_visualize_pairs.py:
Visualize pairs
===============
In this example we are going to a visualize a multidimensional sample by drawing each pair of 2-d marginal clouds.
.. code-block:: default
from __future__ import print_function
import openturns as ot
import openturns.viewer as viewer
from matplotlib import pylab as plt
ot.Log.Show(ot.Log.NONE)
Create data to visualize
.. code-block:: default
R = ot.CorrelationMatrix(3)
for i in range(1, 3):
R[i, i - 1] = -0.4
distribution = ot.Normal([0.] * 3, [5.] * 3, R)
sample = distribution.getSample(200)
Create cloud pairs graphs
.. code-block:: default
graph = ot.Graph("Cloud pairs graph", " ", " ", True, "")
graph = ot.VisualTest.DrawPairs(sample)
view = viewer.View(graph)
plt.show()
.. image:: /auto_data_analysis/graphics/images/sphx_glr_plot_visualize_pairs_001.png
:alt: plot visualize pairs
:class: sphx-glr-single-img
.. rst-class:: sphx-glr-timing
**Total running time of the script:** ( 0 minutes 0.183 seconds)
.. _sphx_glr_download_auto_data_analysis_graphics_plot_visualize_pairs.py:
.. only :: html
.. container:: sphx-glr-footer
:class: sphx-glr-footer-example
.. container:: sphx-glr-download sphx-glr-download-python
:download:`Download Python source code: plot_visualize_pairs.py `
.. container:: sphx-glr-download sphx-glr-download-jupyter
:download:`Download Jupyter notebook: plot_visualize_pairs.ipynb `
.. only:: html
.. rst-class:: sphx-glr-signature
`Gallery generated by Sphinx-Gallery `_