-
Notifications
You must be signed in to change notification settings - Fork 60
Expand file tree
/
Copy pathindex.html
More file actions
3485 lines (3460 loc) · 306 KB
/
index.html
File metadata and controls
3485 lines (3460 loc) · 306 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Gallery — Matplotlib 3.1.3 documentation</title>
<link rel="stylesheet" href="../_static/mpl.css?v3.1.3-2-g782f6ef56"
type="text/css" />
<link rel="stylesheet" href="../_static/pygments.css"
type="text/css" />
<link rel="stylesheet" href="../_static/graphviz.css" type="text/css" />
<link rel="stylesheet" href="../_static/gallery.css" type="text/css" />
<link rel="stylesheet" href="../_static/copybutton.css" type="text/css" />
<script type="text/javascript" id="documentation_options" data-url_root="../" src="../_static/documentation_options.js"></script>
<script type="text/javascript" src="../_static/jquery.js"></script>
<script type="text/javascript" src="../_static/underscore.js"></script>
<script type="text/javascript" src="../_static/doctools.js"></script>
<script type="text/javascript" src="../_static/language_data.js"></script>
<script type="text/javascript" src="../_static/clipboard.min.js"></script>
<script type="text/javascript" src="../_static/copybutton.js"></script>
<script type="text/javascript">var copybuttonSkipText = '>>> ';</script>
<script async="async" type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/latest.js?config=TeX-AMS-MML_HTMLorMML"></script>
<link rel="search" type="application/opensearchdescription+xml"
title="Search within Matplotlib 3.1.3 documentation"
href="../_static/opensearch.xml"/>
<link rel="shortcut icon" href="../_static/favicon.ico"/>
<link rel="index" title="Index" href="../genindex.html"
/>
<link rel="search" title="Search" href="../search.html"
/>
<link rel="top" title="Matplotlib 3.1.3 documentation" href="../index.html" />
<link rel="canonical" href="https://matplotlib.org/stable/gallery/index.html" />
<script data-domain="matplotlib.org" defer="defer" src="https://views.scientific-python.org/js/script.js"></script>
</head>
<body>
<div id="unreleased-message"> You are reading an old version of the documentation (v3.1.3). For the latest version see <a href="https://matplotlib.org/stable/gallery/index.html">https://matplotlib.org/stable/gallery/index.html</a></div>
<div style="background-color: white; text-align: left; padding: 10px 10px 15px 15px; position: relative;">
<a href="../index.html">
<div style="float: left; position: absolute; width: 496px; bottom: 0; padding-bottom: 24px"><span style="float: right; color: #789; background: white">Version 3.1.3</span></div>
<img src="../_static/logo2_compressed.svg" height="125px" border="0" alt="matplotlib"/></a>
<!-- The "Fork me on github" ribbon -->
<div id="forkongithub"><a href="https://github.com/matplotlib/matplotlib">Fork me on GitHub</a></div>
</div>
<nav class="main-nav">
<ul>
<li><a href="../users/installing.html">Installation</a></li>
<li><a href="../contents.html">Documentation</a></li>
<li><a href="#">Examples</a></li>
<li><a href="../tutorials/index.html">Tutorials</a></li>
<li><a href="../devel/index.html">Contributing</a></li>
<li class="nav-right">
<form class="search" action="../search.html" method="get">
<input type="text" name="q" aria-labelledby="searchlabel" placeholder="Search"/>
</form>
</li>
</ul>
</nav>
<div class="related">
<h3>Navigation</h3>
<ul>
<li class="right" style="margin-right: 10px">
<a href="../genindex.html" title="General Index"
accesskey="I">index</a></li>
<li class="right" >
<a href="../py-modindex.html" title="Python Module Index"
>modules</a> |</li>
<li><a href="../index.html">home</a>| </li>
<li><a href="../contents.html">contents</a> »</li>
</ul>
</div>
<div class="sphinxsidebar">
<div class="sphinxsidebarwrapper">
<h3><a href="../contents.html">Table of Contents</a></h3>
<ul>
<li><a class="reference internal" href="#">Gallery</a><ul>
<li><a class="reference internal" href="#lines-bars-and-markers">Lines, bars and markers</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#images-contours-and-fields">Images, contours and fields</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#subplots-axes-and-figures">Subplots, axes and figures</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#statistics">Statistics</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#pie-and-polar-charts">Pie and polar charts</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#text-labels-and-annotations">Text, labels and annotations</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#pyplot">Pyplot</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#color">Color</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#shapes-and-collections">Shapes and collections</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#style-sheets">Style sheets</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#axes-grid">Axes Grid</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#axis-artist">Axis Artist</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#showcase">Showcase</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#animation">Animation</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#event-handling">Event handling</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#front-page">Front Page</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#miscellaneous">Miscellaneous</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#d-plotting">3D plotting</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#our-favorite-recipes">Our Favorite Recipes</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#scales">Scales</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#specialty-plots">Specialty Plots</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#ticks-and-spines">Ticks and spines</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#units">Units</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#embedding-matplotlib-in-graphical-user-interfaces">Embedding Matplotlib in graphical user interfaces</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#userdemo">Userdemo</a><ul>
</ul>
</li>
<li><a class="reference internal" href="#widgets">Widgets</a><ul>
</ul>
</li>
</ul>
</li>
</ul>
<div class="relations">
<h3>Related Topics</h3>
<ul>
<li><a href="../contents.html">Documentation overview</a><ul>
</ul></li>
</ul>
</div>
<div id="sidebar-pagesource" role="note" aria-label="source link"
style="margin-top: 1.5em; padding-top: 0.1em; border-top: 1px solid #86989b">
<a href="../_sources/gallery/index.rst.txt"
style="color: #c0c0c0" rel="nofollow">Show Page Source</a>
</div>
</div>
</div>
<div class="document">
<div class="documentwrapper">
<div class="bodywrapper">
<div class="body">
<div class="section" id="gallery">
<span id="examples-index"></span><span id="sphx-glr-gallery"></span><span id="id1"></span><h1>Gallery<a class="headerlink" href="#gallery" title="Permalink to this headline">¶</a></h1>
<p>This gallery contains examples of the many things you can do with
Matplotlib. Click on any image to see the full image and source code.</p>
<p>For longer tutorials, see our <a class="reference external" href="../tutorials/index.html">tutorials page</a>.
You can also find <a class="reference external" href="../resources/index.html">external resources</a> and
a <a class="reference external" href="../faq/index.html">FAQ</a> in our <a class="reference external" href="../contents.html">user guide</a>.</p>
<div class="sphx-glr-clear"></div><div class="section" id="lines-bars-and-markers">
<span id="lines-bars-and-markers-example"></span><span id="sphx-glr-gallery-lines-bars-and-markers"></span><h2>Lines, bars and markers<a class="headerlink" href="#lines-bars-and-markers" title="Permalink to this headline">¶</a></h2>
<div class="sphx-glr-thumbcontainer" tooltip="This is an example of creating a stacked bar plot with error bars using ~matplotlib.pyplot.bar...."><div class="figure" id="id5">
<img alt="../_images/sphx_glr_bar_stacked_thumb.png" src="../_images/sphx_glr_bar_stacked_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/bar_stacked.html#sphx-glr-gallery-lines-bars-and-markers-bar-stacked-py"><span class="std std-ref">Stacked Bar Graph</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example shows a how to create a grouped bar chart and how to annotate bars with labels."><div class="figure" id="id6">
<img alt="../_images/sphx_glr_barchart_thumb.png" src="../_images/sphx_glr_barchart_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/barchart.html#sphx-glr-gallery-lines-bars-and-markers-barchart-py"><span class="std std-ref">Grouped bar chart with labels</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example showcases a simple horizontal bar chart."><div class="figure" id="id7">
<img alt="../_images/sphx_glr_barh_thumb.png" src="../_images/sphx_glr_barh_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/barh.html#sphx-glr-gallery-lines-bars-and-markers-barh-py"><span class="std std-ref">Horizontal bar chart</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Make a "broken" horizontal bar plot, i.e., one with gaps"><div class="figure" id="id8">
<img alt="../_images/sphx_glr_broken_barh_thumb.png" src="../_images/sphx_glr_broken_barh_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/broken_barh.html#sphx-glr-gallery-lines-bars-and-markers-broken-barh-py"><span class="std std-ref">Broken Barh</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="How to use categorical variables in Matplotlib."><div class="figure" id="id9">
<img alt="../_images/sphx_glr_categorical_variables_thumb.png" src="../_images/sphx_glr_categorical_variables_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/categorical_variables.html#sphx-glr-gallery-lines-bars-and-markers-categorical-variables-py"><span class="std std-ref">Plotting categorical variables</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="An example showing how to plot the coherence of two signals."><div class="figure" id="id10">
<img alt="../_images/sphx_glr_cohere_thumb.png" src="../_images/sphx_glr_cohere_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/cohere.html#sphx-glr-gallery-lines-bars-and-markers-cohere-py"><span class="std std-ref">Plotting the coherence of two signals</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Compute the cross spectral density of two signals"><div class="figure" id="id11">
<img alt="../_images/sphx_glr_csd_demo_thumb.png" src="../_images/sphx_glr_csd_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/csd_demo.html#sphx-glr-gallery-lines-bars-and-markers-csd-demo-py"><span class="std std-ref">CSD Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Illustration of selectively drawing lower and/or upper limit symbols on errorbars using the par..."><div class="figure" id="id12">
<img alt="../_images/sphx_glr_errorbar_limits_simple_thumb.png" src="../_images/sphx_glr_errorbar_limits_simple_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/errorbar_limits_simple.html#sphx-glr-gallery-lines-bars-and-markers-errorbar-limits-simple-py"><span class="std std-ref">Errorbar limit selection</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demo for the errorevery keyword to show data full accuracy data plots with few errorbars."><div class="figure" id="id13">
<img alt="../_images/sphx_glr_errorbar_subsample_thumb.png" src="../_images/sphx_glr_errorbar_subsample_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/errorbar_subsample.html#sphx-glr-gallery-lines-bars-and-markers-errorbar-subsample-py"><span class="std std-ref">Errorbar Subsample</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Plot two curves, then use EventCollections to mark the locations of the x and y data points on ..."><div class="figure" id="id14">
<img alt="../_images/sphx_glr_eventcollection_demo_thumb.png" src="../_images/sphx_glr_eventcollection_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/eventcollection_demo.html#sphx-glr-gallery-lines-bars-and-markers-eventcollection-demo-py"><span class="std std-ref">EventCollection Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="An eventplot showing sequences of events with various line properties. The plot is shown in bot..."><div class="figure" id="id15">
<img alt="../_images/sphx_glr_eventplot_demo_thumb.png" src="../_images/sphx_glr_eventplot_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/eventplot_demo.html#sphx-glr-gallery-lines-bars-and-markers-eventplot-demo-py"><span class="std std-ref">Eventplot Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="~.Axes.fill() draws a filled polygon based based on lists of point coordinates *x*, *y*."><div class="figure" id="id16">
<img alt="../_images/sphx_glr_fill_thumb.png" src="../_images/sphx_glr_fill_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/fill.html#sphx-glr-gallery-lines-bars-and-markers-fill-py"><span class="std std-ref">Filled polygon</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example shows how to use ~.axes.Axes.fill_between to color the area between two lines."><div class="figure" id="id17">
<img alt="../_images/sphx_glr_fill_between_demo_thumb.png" src="../_images/sphx_glr_fill_between_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/fill_between_demo.html#sphx-glr-gallery-lines-bars-and-markers-fill-between-demo-py"><span class="std std-ref">Filling the area between lines</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Using ~.Axes.fill_betweenx to color along the horizontal direction between two curves."><div class="figure" id="id18">
<img alt="../_images/sphx_glr_fill_betweenx_demo_thumb.png" src="../_images/sphx_glr_fill_betweenx_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/fill_betweenx_demo.html#sphx-glr-gallery-lines-bars-and-markers-fill-betweenx-demo-py"><span class="std std-ref">Fill Betweenx Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Hatching capabilities for plotting histograms."><div class="figure" id="id19">
<img alt="../_images/sphx_glr_filled_step_thumb.png" src="../_images/sphx_glr_filled_step_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/filled_step.html#sphx-glr-gallery-lines-bars-and-markers-filled-step-py"><span class="std std-ref">Hatch-filled histograms</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Matplotlib does not natively support gradients. However, we can emulate a gradient-filled recta..."><div class="figure" id="id20">
<img alt="../_images/sphx_glr_gradient_bar_thumb.png" src="../_images/sphx_glr_gradient_bar_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/gradient_bar.html#sphx-glr-gallery-lines-bars-and-markers-gradient-bar-py"><span class="std std-ref">Bar chart with gradients</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Stacked bar charts can be used to visualize discrete distributions."><div class="figure" id="id21">
<img alt="../_images/sphx_glr_horizontal_barchart_distribution_thumb.png" src="../_images/sphx_glr_horizontal_barchart_distribution_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/horizontal_barchart_distribution.html#sphx-glr-gallery-lines-bars-and-markers-horizontal-barchart-distribution-py"><span class="std std-ref">Discrete distribution as horizontal bar chart</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example demonstrates the available join styles and cap styles."><div class="figure" id="id22">
<img alt="../_images/sphx_glr_joinstyle_thumb.png" src="../_images/sphx_glr_joinstyle_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/joinstyle.html#sphx-glr-gallery-lines-bars-and-markers-joinstyle-py"><span class="std std-ref">Join styles and cap styles</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="The dashing of a line is controlled via a dash sequence. It can be modified using .Line2D.set_d..."><div class="figure" id="id23">
<img alt="../_images/sphx_glr_line_demo_dash_control_thumb.png" src="../_images/sphx_glr_line_demo_dash_control_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/line_demo_dash_control.html#sphx-glr-gallery-lines-bars-and-markers-line-demo-dash-control-py"><span class="std std-ref">Customizing dashed line styles</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Simple linestyles can be defined using the strings "solid", "dotted", "dashed" or "dashdot". Mo..."><div class="figure" id="id24">
<img alt="../_images/sphx_glr_linestyles_thumb.png" src="../_images/sphx_glr_linestyles_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/linestyles.html#sphx-glr-gallery-lines-bars-and-markers-linestyles-py"><span class="std std-ref">Linestyles</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Reference for marker fill-styles included with Matplotlib."><div class="figure" id="id25">
<img alt="../_images/sphx_glr_marker_fillstyle_reference_thumb.png" src="../_images/sphx_glr_marker_fillstyle_reference_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/marker_fillstyle_reference.html#sphx-glr-gallery-lines-bars-and-markers-marker-fillstyle-reference-py"><span class="std std-ref">Marker filling-styles</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Reference for filled-, unfilled- and custom marker types with Matplotlib."><div class="figure" id="id26">
<img alt="../_images/sphx_glr_marker_reference_thumb.png" src="../_images/sphx_glr_marker_reference_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/marker_reference.html#sphx-glr-gallery-lines-bars-and-markers-marker-reference-py"><span class="std std-ref">Marker Reference</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example demonstrates the various options for showing a marker at a subset of data points u..."><div class="figure" id="id27">
<img alt="../_images/sphx_glr_markevery_demo_thumb.png" src="../_images/sphx_glr_markevery_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/markevery_demo.html#sphx-glr-gallery-lines-bars-and-markers-markevery-demo-py"><span class="std std-ref">Markevery Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example demonstrates a working solution to issue #8576, providing full support of the mark..."><div class="figure" id="id28">
<img alt="../_images/sphx_glr_markevery_prop_cycle_thumb.png" src="../_images/sphx_glr_markevery_prop_cycle_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/markevery_prop_cycle.html#sphx-glr-gallery-lines-bars-and-markers-markevery-prop-cycle-py"><span class="std std-ref">prop_cycle property markevery in rcParams</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Plot lines with points masked out."><div class="figure" id="id29">
<img alt="../_images/sphx_glr_masked_demo_thumb.png" src="../_images/sphx_glr_masked_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/masked_demo.html#sphx-glr-gallery-lines-bars-and-markers-masked-demo-py"><span class="std std-ref">Masked Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example shows how to make a multi-colored line. In this example, the line is colored based..."><div class="figure" id="id30">
<img alt="../_images/sphx_glr_multicolored_line_thumb.png" src="../_images/sphx_glr_multicolored_line_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/multicolored_line.html#sphx-glr-gallery-lines-bars-and-markers-multicolored-line-py"><span class="std std-ref">Multicolored lines</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Example: simple line plots with NaNs inserted."><div class="figure" id="id31">
<img alt="../_images/sphx_glr_nan_test_thumb.png" src="../_images/sphx_glr_nan_test_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/nan_test.html#sphx-glr-gallery-lines-bars-and-markers-nan-test-py"><span class="std std-ref">Nan Test</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Plotting Power Spectral Density (PSD) in Matplotlib."><div class="figure" id="id32">
<img alt="../_images/sphx_glr_psd_demo_thumb.png" src="../_images/sphx_glr_psd_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/psd_demo.html#sphx-glr-gallery-lines-bars-and-markers-psd-demo-py"><span class="std std-ref">Psd Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Creating a custom ellipse symbol in scatter plot."><div class="figure" id="id33">
<img alt="../_images/sphx_glr_scatter_custom_symbol_thumb.png" src="../_images/sphx_glr_scatter_custom_symbol_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/scatter_custom_symbol.html#sphx-glr-gallery-lines-bars-and-markers-scatter-custom-symbol-py"><span class="std std-ref">Scatter Custom Symbol</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demo of scatter plot with varying marker colors and sizes."><div class="figure" id="id34">
<img alt="../_images/sphx_glr_scatter_demo2_thumb.png" src="../_images/sphx_glr_scatter_demo2_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/scatter_demo2.html#sphx-glr-gallery-lines-bars-and-markers-scatter-demo2-py"><span class="std std-ref">Scatter Demo2</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Create a scatter plot with histograms to its sides."><div class="figure" id="id35">
<img alt="../_images/sphx_glr_scatter_hist_thumb.png" src="../_images/sphx_glr_scatter_hist_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/scatter_hist.html#sphx-glr-gallery-lines-bars-and-markers-scatter-hist-py"><span class="std std-ref">Scatter plot with histograms</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Mask some data points and add a line demarking masked regions."><div class="figure" id="id36">
<img alt="../_images/sphx_glr_scatter_masked_thumb.png" src="../_images/sphx_glr_scatter_masked_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/scatter_masked.html#sphx-glr-gallery-lines-bars-and-markers-scatter-masked-py"><span class="std std-ref">Scatter Masked</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example makes custom 'pie charts' as the markers for a scatter plot."><div class="figure" id="id37">
<img alt="../_images/sphx_glr_scatter_piecharts_thumb.png" src="../_images/sphx_glr_scatter_piecharts_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/scatter_piecharts.html#sphx-glr-gallery-lines-bars-and-markers-scatter-piecharts-py"><span class="std std-ref">Scatter plot with pie chart markers</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Create multiple scatter plots with different star symbols."><div class="figure" id="id38">
<img alt="../_images/sphx_glr_scatter_star_poly_thumb.png" src="../_images/sphx_glr_scatter_star_poly_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/scatter_star_poly.html#sphx-glr-gallery-lines-bars-and-markers-scatter-star-poly-py"><span class="std std-ref">Scatter Star Poly</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Scatter plot with clover symbols."><div class="figure" id="id39">
<img alt="../_images/sphx_glr_scatter_symbol_thumb.png" src="../_images/sphx_glr_scatter_symbol_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/scatter_symbol.html#sphx-glr-gallery-lines-bars-and-markers-scatter-symbol-py"><span class="std std-ref">Scatter Symbol</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="To create a scatter plot with a legend one may use a loop and create one ~.Axes.scatter plot pe..."><div class="figure" id="id40">
<img alt="../_images/sphx_glr_scatter_with_legend_thumb.png" src="../_images/sphx_glr_scatter_with_legend_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/scatter_with_legend.html#sphx-glr-gallery-lines-bars-and-markers-scatter-with-legend-py"><span class="std std-ref">Scatter plots with a legend</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Create a simple plot."><div class="figure" id="id41">
<img alt="../_images/sphx_glr_simple_plot_thumb.png" src="../_images/sphx_glr_simple_plot_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/simple_plot.html#sphx-glr-gallery-lines-bars-and-markers-simple-plot-py"><span class="std std-ref">Simple Plot</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Illustrate some helper functions for shading regions where a logical mask is True."><div class="figure" id="id42">
<img alt="../_images/sphx_glr_span_regions_thumb.png" src="../_images/sphx_glr_span_regions_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/span_regions.html#sphx-glr-gallery-lines-bars-and-markers-span-regions-py"><span class="std std-ref">Using span_where</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="The plots show different spectrum representations of a sine signal with additive noise. A (freq..."><div class="figure" id="id43">
<img alt="../_images/sphx_glr_spectrum_demo_thumb.png" src="../_images/sphx_glr_spectrum_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/spectrum_demo.html#sphx-glr-gallery-lines-bars-and-markers-spectrum-demo-py"><span class="std std-ref">Spectrum Representations</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="How to create stackplots with Matplotlib."><div class="figure" id="id44">
<img alt="../_images/sphx_glr_stackplot_demo_thumb.png" src="../_images/sphx_glr_stackplot_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/stackplot_demo.html#sphx-glr-gallery-lines-bars-and-markers-stackplot-demo-py"><span class="std std-ref">Stackplot Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="~.pyplot.stem plots vertical lines from a baseline to the y-coordinate and places a marker at t..."><div class="figure" id="id45">
<img alt="../_images/sphx_glr_stem_plot_thumb.png" src="../_images/sphx_glr_stem_plot_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/stem_plot.html#sphx-glr-gallery-lines-bars-and-markers-stem-plot-py"><span class="std std-ref">Stem Plot</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example demonstrates the use of .pyplot.step for piece-wise constant curves. In particular..."><div class="figure" id="id46">
<img alt="../_images/sphx_glr_step_demo_thumb.png" src="../_images/sphx_glr_step_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/step_demo.html#sphx-glr-gallery-lines-bars-and-markers-step-demo-py"><span class="std std-ref">Step Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="How to create a simple timeline using Matplotlib release dates."><div class="figure" id="id47">
<img alt="../_images/sphx_glr_timeline_thumb.png" src="../_images/sphx_glr_timeline_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/timeline.html#sphx-glr-gallery-lines-bars-and-markers-timeline-py"><span class="std std-ref">Creating a timeline with lines, dates, and text</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example showcases the functions hlines and vlines."><div class="figure" id="id48">
<img alt="../_images/sphx_glr_vline_hline_demo_thumb.png" src="../_images/sphx_glr_vline_hline_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/vline_hline_demo.html#sphx-glr-gallery-lines-bars-and-markers-vline-hline-demo-py"><span class="std std-ref">hlines and vlines</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Example use of cross-correlation (`~.Axes.xcorr`) and auto-correlation (`~.Axes.acorr`) plots."><div class="figure" id="id49">
<img alt="../_images/sphx_glr_xcorr_acorr_demo_thumb.png" src="../_images/sphx_glr_xcorr_acorr_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="lines_bars_and_markers/xcorr_acorr_demo.html#sphx-glr-gallery-lines-bars-and-markers-xcorr-acorr-demo-py"><span class="std std-ref">Cross- and Auto-Correlation Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-clear"></div></div>
<div class="section" id="images-contours-and-fields">
<span id="images-contours-and-fields-examples"></span><span id="sphx-glr-gallery-images-contours-and-fields"></span><h2>Images, contours and fields<a class="headerlink" href="#images-contours-and-fields" title="Permalink to this headline">¶</a></h2>
<div class="sphx-glr-thumbcontainer" tooltip=" Prepending an affine transformation (:class:`~.transforms.Affine2D`) to the data transform <da..."><div class="figure" id="id50">
<img alt="../_images/sphx_glr_affine_image_thumb.png" src="../_images/sphx_glr_affine_image_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/affine_image.html#sphx-glr-gallery-images-contours-and-fields-affine-image-py"><span class="std std-ref">Affine transform of an image</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demonstration of wind barb plots"><div class="figure" id="id51">
<img alt="../_images/sphx_glr_barb_demo_thumb.png" src="../_images/sphx_glr_barb_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/barb_demo.html#sphx-glr-gallery-images-contours-and-fields-barb-demo-py"><span class="std std-ref">Barb Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This demo shows how to produce a one-dimensional image, or "bar code"."><div class="figure" id="id52">
<img alt="../_images/sphx_glr_barcode_demo_thumb.png" src="../_images/sphx_glr_barcode_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/barcode_demo.html#sphx-glr-gallery-images-contours-and-fields-barcode-demo-py"><span class="std std-ref">Barcode Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Illustrate the difference between corner_mask=False and corner_mask=True for masked contour plo..."><div class="figure" id="id53">
<img alt="../_images/sphx_glr_contour_corner_mask_thumb.png" src="../_images/sphx_glr_contour_corner_mask_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/contour_corner_mask.html#sphx-glr-gallery-images-contours-and-fields-contour-corner-mask-py"><span class="std std-ref">Contour Corner Mask</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Illustrate simple contour plotting, contours on an image with a colorbar for the contours, and ..."><div class="figure" id="id54">
<img alt="../_images/sphx_glr_contour_demo_thumb.png" src="../_images/sphx_glr_contour_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/contour_demo.html#sphx-glr-gallery-images-contours-and-fields-contour-demo-py"><span class="std std-ref">Contour Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Test combinations of contouring, filled contouring, and image plotting. For contour labelling, ..."><div class="figure" id="id55">
<img alt="../_images/sphx_glr_contour_image_thumb.png" src="../_images/sphx_glr_contour_image_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/contour_image.html#sphx-glr-gallery-images-contours-and-fields-contour-image-py"><span class="std std-ref">Contour Image</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Illustrate some of the more advanced things that one can do with contour labels."><div class="figure" id="id56">
<img alt="../_images/sphx_glr_contour_label_demo_thumb.png" src="../_images/sphx_glr_contour_label_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/contour_label_demo.html#sphx-glr-gallery-images-contours-and-fields-contour-label-demo-py"><span class="std std-ref">Contour Label Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="How to use the .axes.Axes.contourf method to create filled contour plots."><div class="figure" id="id57">
<img alt="../_images/sphx_glr_contourf_demo_thumb.png" src="../_images/sphx_glr_contourf_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/contourf_demo.html#sphx-glr-gallery-images-contours-and-fields-contourf-demo-py"><span class="std std-ref">Contourf Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demo filled contour plots with hatched patterns."><div class="figure" id="id58">
<img alt="../_images/sphx_glr_contourf_hatching_thumb.png" src="../_images/sphx_glr_contourf_hatching_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/contourf_hatching.html#sphx-glr-gallery-images-contours-and-fields-contourf-hatching-py"><span class="std std-ref">Contourf Hatching</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demonstrate use of a log color scale in contourf"><div class="figure" id="id59">
<img alt="../_images/sphx_glr_contourf_log_thumb.png" src="../_images/sphx_glr_contourf_log_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/contourf_log.html#sphx-glr-gallery-images-contours-and-fields-contourf-log-py"><span class="std std-ref">Contourf and log color scale</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="A BboxImage can be used to position an image according to a bounding box. This demo shows how t..."><div class="figure" id="id60">
<img alt="../_images/sphx_glr_demo_bboximage_thumb.png" src="../_images/sphx_glr_demo_bboximage_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/demo_bboximage.html#sphx-glr-gallery-images-contours-and-fields-demo-bboximage-py"><span class="std std-ref">BboxImage Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This illustrates placing images directly in the figure, with no Axes objects."><div class="figure" id="id61">
<img alt="../_images/sphx_glr_figimage_demo_thumb.png" src="../_images/sphx_glr_figimage_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/figimage_demo.html#sphx-glr-gallery-images-contours-and-fields-figimage-demo-py"><span class="std std-ref">Figimage Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="It is often desirable to show data which depends on two independent variables as a color coded ..."><div class="figure" id="id62">
<img alt="../_images/sphx_glr_image_annotated_heatmap_thumb.png" src="../_images/sphx_glr_image_annotated_heatmap_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/image_annotated_heatmap.html#sphx-glr-gallery-images-contours-and-fields-image-annotated-heatmap-py"><span class="std std-ref">Creating annotated heatmaps</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demo of image that's been clipped by a circular patch."><div class="figure" id="id63">
<img alt="../_images/sphx_glr_image_clip_path_thumb.png" src="../_images/sphx_glr_image_clip_path_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/image_clip_path.html#sphx-glr-gallery-images-contours-and-fields-image-clip-path-py"><span class="std std-ref">Clipping images with patches</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Many ways to plot images in Matplotlib."><div class="figure" id="id64">
<img alt="../_images/sphx_glr_image_demo_thumb.png" src="../_images/sphx_glr_image_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/image_demo.html#sphx-glr-gallery-images-contours-and-fields-image-demo-py"><span class="std std-ref">Image Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="imshow with masked array input and out-of-range colors."><div class="figure" id="id65">
<img alt="../_images/sphx_glr_image_masked_thumb.png" src="../_images/sphx_glr_image_masked_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/image_masked.html#sphx-glr-gallery-images-contours-and-fields-image-masked-py"><span class="std std-ref">Image Masked</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This illustrates the NonUniformImage class. It is not available via an Axes method but it is e..."><div class="figure" id="id66">
<img alt="../_images/sphx_glr_image_nonuniform_thumb.png" src="../_images/sphx_glr_image_nonuniform_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/image_nonuniform.html#sphx-glr-gallery-images-contours-and-fields-image-nonuniform-py"><span class="std std-ref">Image Nonuniform</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Blend transparency with color to highlight parts of data with imshow."><div class="figure" id="id67">
<img alt="../_images/sphx_glr_image_transparency_blend_thumb.png" src="../_images/sphx_glr_image_transparency_blend_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/image_transparency_blend.html#sphx-glr-gallery-images-contours-and-fields-image-transparency-blend-py"><span class="std std-ref">Blend transparency with color in 2-D images</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Modify the coordinate formatter to report the image "z" value of the nearest pixel given x and ..."><div class="figure" id="id68">
<img alt="../_images/sphx_glr_image_zcoord_thumb.png" src="../_images/sphx_glr_image_zcoord_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/image_zcoord.html#sphx-glr-gallery-images-contours-and-fields-image-zcoord-py"><span class="std std-ref">Modifying the coordinate formatter</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example displays the difference between interpolation methods for imshow and matshow."><div class="figure" id="id69">
<img alt="../_images/sphx_glr_interpolation_methods_thumb.png" src="../_images/sphx_glr_interpolation_methods_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/interpolation_methods.html#sphx-glr-gallery-images-contours-and-fields-interpolation-methods-py"><span class="std std-ref">Interpolations for imshow/matshow</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Comparison of a contour plot of irregularly spaced data interpolated on a regular grid versus a..."><div class="figure" id="id70">
<img alt="../_images/sphx_glr_irregulardatagrid_thumb.png" src="../_images/sphx_glr_irregulardatagrid_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/irregulardatagrid.html#sphx-glr-gallery-images-contours-and-fields-irregulardatagrid-py"><span class="std std-ref">Contour plot of irregularly spaced data</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Layer images above one another using alpha blending"><div class="figure" id="id71">
<img alt="../_images/sphx_glr_layer_images_thumb.png" src="../_images/sphx_glr_layer_images_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/layer_images.html#sphx-glr-gallery-images-contours-and-fields-layer-images-py"><span class="std std-ref">Layer Images</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Simple ~.axes.Axes.matshow example."><div class="figure" id="id72">
<img alt="../_images/sphx_glr_matshow_thumb.png" src="../_images/sphx_glr_matshow_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/matshow.html#sphx-glr-gallery-images-contours-and-fields-matshow-py"><span class="std std-ref">Matshow</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Make a set of images with a single colormap, norm, and colorbar."><div class="figure" id="id73">
<img alt="../_images/sphx_glr_multi_image_thumb.png" src="../_images/sphx_glr_multi_image_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/multi_image.html#sphx-glr-gallery-images-contours-and-fields-multi-image-py"><span class="std std-ref">Multi Image</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Generating images with pcolor."><div class="figure" id="id74">
<img alt="../_images/sphx_glr_pcolor_demo_thumb.png" src="../_images/sphx_glr_pcolor_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/pcolor_demo.html#sphx-glr-gallery-images-contours-and-fields-pcolor-demo-py"><span class="std std-ref">Pcolor Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Shows how to combine Normalization and Colormap instances to draw "levels" in pcolor, pcolormes..."><div class="figure" id="id75">
<img alt="../_images/sphx_glr_pcolormesh_levels_thumb.png" src="../_images/sphx_glr_pcolormesh_levels_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/pcolormesh_levels.html#sphx-glr-gallery-images-contours-and-fields-pcolormesh-levels-py"><span class="std std-ref">pcolormesh</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="A stream plot, or streamline plot, is used to display 2D vector fields. This example shows a fe..."><div class="figure" id="id76">
<img alt="../_images/sphx_glr_plot_streamplot_thumb.png" src="../_images/sphx_glr_plot_streamplot_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/plot_streamplot.html#sphx-glr-gallery-images-contours-and-fields-plot-streamplot-py"><span class="std std-ref">Streamplot</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="~.axes.Axes.pcolormesh uses a ~matplotlib.collections.QuadMesh, a faster generalization of ~.ax..."><div class="figure" id="id77">
<img alt="../_images/sphx_glr_quadmesh_demo_thumb.png" src="../_images/sphx_glr_quadmesh_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/quadmesh_demo.html#sphx-glr-gallery-images-contours-and-fields-quadmesh-demo-py"><span class="std std-ref">QuadMesh Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demonstrates some more advanced options for ~.axes.Axes.quiver. For a simple example refer to ..."><div class="figure" id="id78">
<img alt="../_images/sphx_glr_quiver_demo_thumb.png" src="../_images/sphx_glr_quiver_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/quiver_demo.html#sphx-glr-gallery-images-contours-and-fields-quiver-demo-py"><span class="std std-ref">Advanced quiver and quiverkey functions</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="A simple example of a ~.axes.Axes.quiver plot with a ~.axes.Axes.quiverkey."><div class="figure" id="id79">
<img alt="../_images/sphx_glr_quiver_simple_demo_thumb.png" src="../_images/sphx_glr_quiver_simple_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/quiver_simple_demo.html#sphx-glr-gallery-images-contours-and-fields-quiver-simple-demo-py"><span class="std std-ref">Quiver Simple Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Example showing how to make shaded relief plots like Mathematica_ or `Generic Mapping Tools`_."><div class="figure" id="id80">
<img alt="../_images/sphx_glr_shading_example_thumb.png" src="../_images/sphx_glr_shading_example_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/shading_example.html#sphx-glr-gallery-images-contours-and-fields-shading-example-py"><span class="std std-ref">Shading example</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demo of a spectrogram plot (`~.axes.Axes.specgram`)."><div class="figure" id="id81">
<img alt="../_images/sphx_glr_specgram_demo_thumb.png" src="../_images/sphx_glr_specgram_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/specgram_demo.html#sphx-glr-gallery-images-contours-and-fields-specgram-demo-py"><span class="std std-ref">Spectrogram Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Plot the sparsity pattern of arrays."><div class="figure" id="id82">
<img alt="../_images/sphx_glr_spy_demos_thumb.png" src="../_images/sphx_glr_spy_demos_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/spy_demos.html#sphx-glr-gallery-images-contours-and-fields-spy-demos-py"><span class="std std-ref">Spy Demos</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Contour plots of unstructured triangular grids."><div class="figure" id="id83">
<img alt="../_images/sphx_glr_tricontour_demo_thumb.png" src="../_images/sphx_glr_tricontour_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/tricontour_demo.html#sphx-glr-gallery-images-contours-and-fields-tricontour-demo-py"><span class="std std-ref">Tricontour Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demonstrates high-resolution tricontouring of a random set of points; a matplotlib.tri.TriAnaly..."><div class="figure" id="id84">
<img alt="../_images/sphx_glr_tricontour_smooth_delaunay_thumb.png" src="../_images/sphx_glr_tricontour_smooth_delaunay_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/tricontour_smooth_delaunay.html#sphx-glr-gallery-images-contours-and-fields-tricontour-smooth-delaunay-py"><span class="std std-ref">Tricontour Smooth Delaunay</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demonstrates high-resolution tricontouring on user-defined triangular grids with matplotlib.tri..."><div class="figure" id="id85">
<img alt="../_images/sphx_glr_tricontour_smooth_user_thumb.png" src="../_images/sphx_glr_tricontour_smooth_user_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/tricontour_smooth_user.html#sphx-glr-gallery-images-contours-and-fields-tricontour-smooth-user-py"><span class="std std-ref">Tricontour Smooth User</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demonstrates computation of gradient with matplotlib.tri.CubicTriInterpolator."><div class="figure" id="id86">
<img alt="../_images/sphx_glr_trigradient_demo_thumb.png" src="../_images/sphx_glr_trigradient_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/trigradient_demo.html#sphx-glr-gallery-images-contours-and-fields-trigradient-demo-py"><span class="std std-ref">Trigradient Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Interpolation from triangular grid to quad grid."><div class="figure" id="id87">
<img alt="../_images/sphx_glr_triinterp_demo_thumb.png" src="../_images/sphx_glr_triinterp_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/triinterp_demo.html#sphx-glr-gallery-images-contours-and-fields-triinterp-demo-py"><span class="std std-ref">Triinterp Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Pseudocolor plots of unstructured triangular grids."><div class="figure" id="id88">
<img alt="../_images/sphx_glr_tripcolor_demo_thumb.png" src="../_images/sphx_glr_tripcolor_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/tripcolor_demo.html#sphx-glr-gallery-images-contours-and-fields-tripcolor-demo-py"><span class="std std-ref">Tripcolor Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Creating and plotting unstructured triangular grids."><div class="figure" id="id89">
<img alt="../_images/sphx_glr_triplot_demo_thumb.png" src="../_images/sphx_glr_triplot_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/triplot_demo.html#sphx-glr-gallery-images-contours-and-fields-triplot-demo-py"><span class="std std-ref">Triplot Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Using a PNG file as a watermark."><div class="figure" id="id90">
<img alt="../_images/sphx_glr_watermark_image_thumb.png" src="../_images/sphx_glr_watermark_image_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="images_contours_and_fields/watermark_image.html#sphx-glr-gallery-images-contours-and-fields-watermark-image-py"><span class="std std-ref">Watermark image</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-clear"></div></div>
<div class="section" id="subplots-axes-and-figures">
<span id="subplots-axes-and-figures-examples"></span><span id="sphx-glr-gallery-subplots-axes-and-figures"></span><h2>Subplots, axes and figures<a class="headerlink" href="#subplots-axes-and-figures" title="Permalink to this headline">¶</a></h2>
<div class="sphx-glr-thumbcontainer" tooltip="Aligning xlabel and ylabel using Figure.align_xlabels and Figure.align_ylabels"><div class="figure" id="id91">
<img alt="../_images/sphx_glr_align_labels_demo_thumb.png" src="../_images/sphx_glr_align_labels_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/align_labels_demo.html#sphx-glr-gallery-subplots-axes-and-figures-align-labels-demo-py"><span class="std std-ref">Aligning Labels</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Example use of fig.add_axes to create inset axes within the main plot axes."><div class="figure" id="id92">
<img alt="../_images/sphx_glr_axes_demo_thumb.png" src="../_images/sphx_glr_axes_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/axes_demo.html#sphx-glr-gallery-subplots-axes-and-figures-axes-demo-py"><span class="std std-ref">Axes Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="The first figure in this example shows how to zoom in and out of a plot using ~.Axes.margins in..."><div class="figure" id="id93">
<img alt="../_images/sphx_glr_axes_margins_thumb.png" src="../_images/sphx_glr_axes_margins_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/axes_margins.html#sphx-glr-gallery-subplots-axes-and-figures-axes-margins-py"><span class="std std-ref">Zooming in and out using Axes.margins and the subject of "stickiness"</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="You can control the axis tick and grid properties"><div class="figure" id="id94">
<img alt="../_images/sphx_glr_axes_props_thumb.png" src="../_images/sphx_glr_axes_props_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/axes_props.html#sphx-glr-gallery-subplots-axes-and-figures-axes-props-py"><span class="std std-ref">Axes Props</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Axes Zoom Effect"><div class="figure" id="id95">
<img alt="../_images/sphx_glr_axes_zoom_effect_thumb.png" src="../_images/sphx_glr_axes_zoom_effect_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/axes_zoom_effect.html#sphx-glr-gallery-subplots-axes-and-figures-axes-zoom-effect-py"><span class="std std-ref">Axes Zoom Effect</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Create lines or rectangles that span the axes in either the horizontal or vertical direction."><div class="figure" id="id96">
<img alt="../_images/sphx_glr_axhspan_demo_thumb.png" src="../_images/sphx_glr_axhspan_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/axhspan_demo.html#sphx-glr-gallery-subplots-axes-and-figures-axhspan-demo-py"><span class="std std-ref">axhspan Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="How to set and adjust plots with equal axis ratios."><div class="figure" id="id97">
<img alt="../_images/sphx_glr_axis_equal_demo_thumb.png" src="../_images/sphx_glr_axis_equal_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/axis_equal_demo.html#sphx-glr-gallery-subplots-axes-and-figures-axis-equal-demo-py"><span class="std std-ref">Axis Equal Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Broken axis example, where the y-axis will have a portion cut out."><div class="figure" id="id98">
<img alt="../_images/sphx_glr_broken_axis_thumb.png" src="../_images/sphx_glr_broken_axis_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/broken_axis.html#sphx-glr-gallery-subplots-axes-and-figures-broken-axis-py"><span class="std std-ref">Broken Axis</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Colorbars indicate the quantitative extent of image data. Placing in a figure is non-trivial b..."><div class="figure" id="id99">
<img alt="../_images/sphx_glr_colorbar_placement_thumb.png" src="../_images/sphx_glr_colorbar_placement_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/colorbar_placement.html#sphx-glr-gallery-subplots-axes-and-figures-colorbar-placement-py"><span class="std std-ref">Placing Colorbars</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="You can pass a custom Figure constructor to figure if you want to derive from the default Figur..."><div class="figure" id="id100">
<img alt="../_images/sphx_glr_custom_figure_class_thumb.png" src="../_images/sphx_glr_custom_figure_class_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/custom_figure_class.html#sphx-glr-gallery-subplots-axes-and-figures-custom-figure-class-py"><span class="std std-ref">Custom Figure Class</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Constrained layout attempts to resize subplots in a figure so that there are no overlaps betwee..."><div class="figure" id="id101">
<img alt="../_images/sphx_glr_demo_constrained_layout_thumb.png" src="../_images/sphx_glr_demo_constrained_layout_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/demo_constrained_layout.html#sphx-glr-gallery-subplots-axes-and-figures-demo-constrained-layout-py"><span class="std std-ref">Resizing axes with constrained layout</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="~.figure.Figure.tight_layout attempts to resize subplots in a figure so that there are no overl..."><div class="figure" id="id102">
<img alt="../_images/sphx_glr_demo_tight_layout_thumb.png" src="../_images/sphx_glr_demo_tight_layout_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/demo_tight_layout.html#sphx-glr-gallery-subplots-axes-and-figures-demo-tight-layout-py"><span class="std std-ref">Resizing axes with tight layout</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demo of how to display two scales on the left and right y axis."><div class="figure" id="id103">
<img alt="../_images/sphx_glr_fahrenheit_celsius_scales_thumb.png" src="../_images/sphx_glr_fahrenheit_celsius_scales_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/fahrenheit_celsius_scales.html#sphx-glr-gallery-subplots-axes-and-figures-fahrenheit-celsius-scales-py"><span class="std std-ref">Different scales on the same axes</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Create a figure with separate subplot titles and a centered figure title."><div class="figure" id="id104">
<img alt="../_images/sphx_glr_figure_title_thumb.png" src="../_images/sphx_glr_figure_title_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/figure_title.html#sphx-glr-gallery-subplots-axes-and-figures-figure-title-py"><span class="std std-ref">Figure Title</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="To create plots that share a common axis (visually) you can set the hspace between the subplots..."><div class="figure" id="id105">
<img alt="../_images/sphx_glr_ganged_plots_thumb.png" src="../_images/sphx_glr_ganged_plots_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/ganged_plots.html#sphx-glr-gallery-subplots-axes-and-figures-ganged-plots-py"><span class="std std-ref">Creating adjacent subplots</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This shows 4 possible projections using subplot. Matplotlib also supports `Basemaps Toolkit <h..."><div class="figure" id="id106">
<img alt="../_images/sphx_glr_geo_demo_thumb.png" src="../_images/sphx_glr_geo_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/geo_demo.html#sphx-glr-gallery-subplots-axes-and-figures-geo-demo-py"><span class="std std-ref">Geographic Projections</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Sometimes we want to combine two subplots in an axes layout created with ~.Figure.subplots. We..."><div class="figure" id="id107">
<img alt="../_images/sphx_glr_gridspec_and_subplots_thumb.png" src="../_images/sphx_glr_gridspec_and_subplots_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/gridspec_and_subplots.html#sphx-glr-gallery-subplots-axes-and-figures-gridspec-and-subplots-py"><span class="std std-ref">Combining two subplots using subplots and GridSpec</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip=".GridSpec is a flexible way to layout subplot grids. Here is an example with a 3x3 grid, and a..."><div class="figure" id="id108">
<img alt="../_images/sphx_glr_gridspec_multicolumn_thumb.png" src="../_images/sphx_glr_gridspec_multicolumn_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/gridspec_multicolumn.html#sphx-glr-gallery-subplots-axes-and-figures-gridspec-multicolumn-py"><span class="std std-ref">Using Gridspec to make multi-column/row subplot layouts</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="GridSpecs can be nested, so that a subplot from a parent GridSpec can set the position for a ne..."><div class="figure" id="id109">
<img alt="../_images/sphx_glr_gridspec_nested_thumb.png" src="../_images/sphx_glr_gridspec_nested_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/gridspec_nested.html#sphx-glr-gallery-subplots-axes-and-figures-gridspec-nested-py"><span class="std std-ref">Nested Gridspecs</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="You can use decreasing axes by flipping the normal order of the axis limits"><div class="figure" id="id110">
<img alt="../_images/sphx_glr_invert_axes_thumb.png" src="../_images/sphx_glr_invert_axes_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/invert_axes.html#sphx-glr-gallery-subplots-axes-and-figures-invert-axes-py"><span class="std std-ref">Invert Axes</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Working with multiple figure windows and subplots"><div class="figure" id="id111">
<img alt="../_images/sphx_glr_multiple_figs_demo_thumb.png" src="../_images/sphx_glr_multiple_figs_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/multiple_figs_demo.html#sphx-glr-gallery-subplots-axes-and-figures-multiple-figs-demo-py"><span class="std std-ref">Multiple Figs Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Sometimes we want as secondary axis on a plot, for instance to convert radians to degrees on th..."><div class="figure" id="id112">
<img alt="../_images/sphx_glr_secondary_axis_thumb.png" src="../_images/sphx_glr_secondary_axis_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/secondary_axis.html#sphx-glr-gallery-subplots-axes-and-figures-secondary-axis-py"><span class="std std-ref">Secondary Axis</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="You can share the x or y axis limits for one axis with another by passing an axes instance as a..."><div class="figure" id="id113">
<img alt="../_images/sphx_glr_shared_axis_demo_thumb.png" src="../_images/sphx_glr_shared_axis_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/shared_axis_demo.html#sphx-glr-gallery-subplots-axes-and-figures-shared-axis-demo-py"><span class="std std-ref">Shared Axis Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Simple demo with multiple subplots."><div class="figure" id="id114">
<img alt="../_images/sphx_glr_subplot_thumb.png" src="../_images/sphx_glr_subplot_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/subplot.html#sphx-glr-gallery-subplots-axes-and-figures-subplot-py"><span class="std std-ref">Multiple subplots</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demo with two subplots. For more options, see /gallery/subplots_axes_and_figures/subplots_demo"><div class="figure" id="id115">
<img alt="../_images/sphx_glr_subplot_demo_thumb.png" src="../_images/sphx_glr_subplot_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/subplot_demo.html#sphx-glr-gallery-subplots-axes-and-figures-subplot-demo-py"><span class="std std-ref">Basic Subplot Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Matplotlib has a toolbar available for adjusting subplot spacing."><div class="figure" id="id116">
<img alt="../_images/sphx_glr_subplot_toolbar_thumb.png" src="../_images/sphx_glr_subplot_toolbar_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/subplot_toolbar.html#sphx-glr-gallery-subplots-axes-and-figures-subplot-toolbar-py"><span class="std std-ref">Subplot Toolbar</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Adjusting the spacing of margins and subplots using subplots_adjust."><div class="figure" id="id117">
<img alt="../_images/sphx_glr_subplots_adjust_thumb.png" src="../_images/sphx_glr_subplots_adjust_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/subplots_adjust.html#sphx-glr-gallery-subplots-axes-and-figures-subplots-adjust-py"><span class="std std-ref">Subplots Adjust</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip=".pyplot.subplots creates a figure and a grid of subplots with a single call, while providing re..."><div class="figure" id="id118">
<img alt="../_images/sphx_glr_subplots_demo_thumb.png" src="../_images/sphx_glr_subplots_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/subplots_demo.html#sphx-glr-gallery-subplots-axes-and-figures-subplots-demo-py"><span class="std std-ref">Creating multiple subplots using plt.subplots</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Two plots on the same axes with different left and right scales."><div class="figure" id="id119">
<img alt="../_images/sphx_glr_two_scales_thumb.png" src="../_images/sphx_glr_two_scales_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/two_scales.html#sphx-glr-gallery-subplots-axes-and-figures-two-scales-py"><span class="std std-ref">Plots with different scales</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Example of an inset axes and a rectangle showing where the zoom is located."><div class="figure" id="id120">
<img alt="../_images/sphx_glr_zoom_inset_axes_thumb.png" src="../_images/sphx_glr_zoom_inset_axes_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="subplots_axes_and_figures/zoom_inset_axes.html#sphx-glr-gallery-subplots-axes-and-figures-zoom-inset-axes-py"><span class="std std-ref">Zoom region inset axes</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-clear"></div></div>
<div class="section" id="statistics">
<span id="statistics-examples"></span><span id="sphx-glr-gallery-statistics"></span><h2>Statistics<a class="headerlink" href="#statistics" title="Permalink to this headline">¶</a></h2>
<div class="sphx-glr-thumbcontainer" tooltip="Bar charts are useful for visualizing counts, or summary statistics with error bars. Also see t..."><div class="figure" id="id121">
<img alt="../_images/sphx_glr_barchart_demo_thumb.png" src="../_images/sphx_glr_barchart_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/barchart_demo.html#sphx-glr-gallery-statistics-barchart-demo-py"><span class="std std-ref">Percentiles as horizontal bar chart</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example demonstrates how to use the various kwargs to fully customize box plots. The first..."><div class="figure" id="id122">
<img alt="../_images/sphx_glr_boxplot_thumb.png" src="../_images/sphx_glr_boxplot_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/boxplot.html#sphx-glr-gallery-statistics-boxplot-py"><span class="std std-ref">Artist customization in box plots</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This plot illustrates how to create two types of box plots (rectangular and notched), and how t..."><div class="figure" id="id123">
<img alt="../_images/sphx_glr_boxplot_color_thumb.png" src="../_images/sphx_glr_boxplot_color_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/boxplot_color.html#sphx-glr-gallery-statistics-boxplot-color-py"><span class="std std-ref">Box plots with custom fill colors</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Visualizing boxplots with matplotlib."><div class="figure" id="id124">
<img alt="../_images/sphx_glr_boxplot_demo_thumb.png" src="../_images/sphx_glr_boxplot_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/boxplot_demo.html#sphx-glr-gallery-statistics-boxplot-demo-py"><span class="std std-ref">Boxplots</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Note that although violin plots are closely related to Tukey's (1977) box plots, they add usefu..."><div class="figure" id="id125">
<img alt="../_images/sphx_glr_boxplot_vs_violin_thumb.png" src="../_images/sphx_glr_boxplot_vs_violin_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/boxplot_vs_violin.html#sphx-glr-gallery-statistics-boxplot-vs-violin-py"><span class="std std-ref">Box plot vs. violin plot comparison</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example demonstrates how to pass pre-computed box plot statistics to the box plot drawer. ..."><div class="figure" id="id126">
<img alt="../_images/sphx_glr_bxp_thumb.png" src="../_images/sphx_glr_bxp_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/bxp.html#sphx-glr-gallery-statistics-bxp-py"><span class="std std-ref">Boxplot drawer function</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example shows how to plot a confidence ellipse of a two-dimensional dataset, using its pea..."><div class="figure" id="id127">
<img alt="../_images/sphx_glr_confidence_ellipse_thumb.png" src="../_images/sphx_glr_confidence_ellipse_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/confidence_ellipse.html#sphx-glr-gallery-statistics-confidence-ellipse-py"><span class="std std-ref">Plot a confidence ellipse of a two-dimensional dataset</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This example demonstrates how to fully customize violin plots. The first plot shows the default..."><div class="figure" id="id128">
<img alt="../_images/sphx_glr_customized_violin_thumb.png" src="../_images/sphx_glr_customized_violin_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/customized_violin.html#sphx-glr-gallery-statistics-customized-violin-py"><span class="std std-ref">Violin plot customization</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This exhibits the most basic use of the error bar method. In this case, constant values are pro..."><div class="figure" id="id129">
<img alt="../_images/sphx_glr_errorbar_thumb.png" src="../_images/sphx_glr_errorbar_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/errorbar.html#sphx-glr-gallery-statistics-errorbar-py"><span class="std std-ref">Errorbar function</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Errors can be specified as a constant value (as shown in errorbar_demo.py). However, this examp..."><div class="figure" id="id130">
<img alt="../_images/sphx_glr_errorbar_features_thumb.png" src="../_images/sphx_glr_errorbar_features_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/errorbar_features.html#sphx-glr-gallery-statistics-errorbar-features-py"><span class="std std-ref">Different ways of specifying error bars</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="In matplotlib, errors bars can have "limits". Applying limits to the error bars essentially mak..."><div class="figure" id="id131">
<img alt="../_images/sphx_glr_errorbar_limits_thumb.png" src="../_images/sphx_glr_errorbar_limits_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/errorbar_limits.html#sphx-glr-gallery-statistics-errorbar-limits-py"><span class="std std-ref">Including upper and lower limits in error bars</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="In this example, we snazz up a pretty standard error bar plot by adding a rectangle patch defin..."><div class="figure" id="id132">
<img alt="../_images/sphx_glr_errorbars_and_boxes_thumb.png" src="../_images/sphx_glr_errorbars_and_boxes_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/errorbars_and_boxes.html#sphx-glr-gallery-statistics-errorbars-and-boxes-py"><span class="std std-ref">Creating boxes from error bars using PatchCollection</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Plotting hexbins with Matplotlib."><div class="figure" id="id133">
<img alt="../_images/sphx_glr_hexbin_demo_thumb.png" src="../_images/sphx_glr_hexbin_demo_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/hexbin_demo.html#sphx-glr-gallery-statistics-hexbin-demo-py"><span class="std std-ref">Hexbin Demo</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="Demonstrates how to plot histograms with matplotlib."><div class="figure" id="id134">
<img alt="../_images/sphx_glr_hist_thumb.png" src="../_images/sphx_glr_hist_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/hist.html#sphx-glr-gallery-statistics-hist-py"><span class="std std-ref">Histograms</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="This shows how to plot a cumulative, normalized histogram as a step function in order to visual..."><div class="figure" id="id135">
<img alt="../_images/sphx_glr_histogram_cumulative_thumb.png" src="../_images/sphx_glr_histogram_cumulative_thumb.png" />
<p class="caption"><span class="caption-text"><a class="reference internal" href="statistics/histogram_cumulative.html#sphx-glr-gallery-statistics-histogram-cumulative-py"><span class="std std-ref">Using histograms to plot a cumulative distribution</span></a></span></p>
</div>
</div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-thumbcontainer" tooltip="In addition to the basic histogram, this demo shows a few optional features:"><div class="figure" id="id136">