summaryrefslogtreecommitdiff
path: root/auto_examples/index.html
blob: fbe1409dc1d516a8ad0bd5e23c210d6f072ed866 (plain)
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

<!DOCTYPE html>

<html lang="en">
  <head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.19: https://docutils.sourceforge.io/" />

    <title>Gallery &#8212; NetworkX 3.0rc2.dev0 documentation</title>
  
  
  
  <script data-cfasync="false">
    document.documentElement.dataset.mode = localStorage.getItem("mode") || "light";
    document.documentElement.dataset.theme = localStorage.getItem("theme") || "light";
  </script>
  
  <!-- Loaded before other Sphinx assets -->
  <link href="../_static/styles/theme.css?digest=796348d33e8b1d947c94" rel="stylesheet">
<link href="../_static/styles/bootstrap.css?digest=796348d33e8b1d947c94" rel="stylesheet">
<link href="../_static/styles/pydata-sphinx-theme.css?digest=796348d33e8b1d947c94" rel="stylesheet">

  
  <link href="../_static/vendor/fontawesome/6.1.2/css/all.min.css?digest=796348d33e8b1d947c94" rel="stylesheet">
  <link rel="preload" as="font" type="font/woff2" crossorigin href="../_static/vendor/fontawesome/6.1.2/webfonts/fa-solid-900.woff2">
<link rel="preload" as="font" type="font/woff2" crossorigin href="../_static/vendor/fontawesome/6.1.2/webfonts/fa-brands-400.woff2">
<link rel="preload" as="font" type="font/woff2" crossorigin href="../_static/vendor/fontawesome/6.1.2/webfonts/fa-regular-400.woff2">

    <link rel="stylesheet" type="text/css" href="../_static/pygments.css" />
    <link rel="stylesheet" type="text/css" href="../_static/custom.css" />
    <link rel="stylesheet" type="text/css" href="../_static/sg_gallery.css" />
    <link rel="stylesheet" type="text/css" href="../_static/sg_gallery-binder.css" />
    <link rel="stylesheet" type="text/css" href="../_static/sg_gallery-dataframe.css" />
    <link rel="stylesheet" type="text/css" href="../_static/sg_gallery-rendered-html.css" />
  
  <!-- Pre-loaded scripts that we'll load fully later -->
  <link rel="preload" as="script" href="../_static/scripts/bootstrap.js?digest=796348d33e8b1d947c94">
<link rel="preload" as="script" href="../_static/scripts/pydata-sphinx-theme.js?digest=796348d33e8b1d947c94">

    <script data-url_root="../" id="documentation_options" src="../_static/documentation_options.js"></script>
    <script src="../_static/jquery.js"></script>
    <script src="../_static/underscore.js"></script>
    <script src="../_static/_sphinx_javascript_frameworks_compat.js"></script>
    <script src="../_static/doctools.js"></script>
    <script src="../_static/sphinx_highlight.js"></script>
    <script src="../_static/copybutton.js"></script>
    <script>DOCUMENTATION_OPTIONS.pagename = 'auto_examples/index';</script>
    <link rel="canonical" href="https://networkx.org/documentation/stable/auto_examples/index.html" />
    <link rel="search" type="application/opensearchdescription+xml"
          title="Search within NetworkX 3.0rc2.dev0 documentation"
          href="../_static/opensearch.xml"/>
    <link rel="index" title="Index" href="../genindex.html" />
    <link rel="search" title="Search" href="../search.html" />
    <link rel="next" title="Basic" href="basic/index.html" />
    <link rel="prev" title="Glossary" href="../reference/glossary.html" />
  <meta name="viewport" content="width=device-width, initial-scale=1" />
  <meta name="docsearch:language" content="en">
  </head>
  
  
  <body data-spy="scroll" data-target="#bd-toc-nav" data-offset="180" data-default-mode="light">

  
  
  <a class="skip-link" href="#main-content">Skip to main content</a> 
<div class="container-fluid version-alert devbar">
  <div class="row no-gutters">
    <div class="col-12 text-center">
      This page is documentation for a DEVELOPMENT / PRE-RELEASE version.
      <a
        class="btn version-stable font-weight-bold ml-3 my-3 align-baseline"
        href="https://networkx.org/documentation/stable/"
        >Switch to stable version</a
      >
    </div>
  </div>
</div>


  
  <input type="checkbox" class="sidebar-toggle" name="__primary" id="__primary">
  <label class="overlay overlay-primary" for="__primary"></label>

  
  <input type="checkbox" class="sidebar-toggle" name="__secondary" id="__secondary">
  <label class="overlay overlay-secondary" for="__secondary"></label>

  
  <div class="search-button__wrapper">
    <div class="search-button__overlay"></div>
    <div class="search-button__search-container">
      
<form class="bd-search d-flex align-items-center" action="../search.html" method="get">
  <i class="fa-solid fa-magnifying-glass"></i>
  <input type="search" class="form-control" name="q" id="search-input" placeholder="Search the docs ..." aria-label="Search the docs ..." autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false">
  <span class="search-button__kbd-shortcut"><kbd class="kbd-shortcut__modifier">Ctrl</kbd>+<kbd>K</kbd></span>
</form>
    </div>
  </div>

  
  <nav class="bd-header navbar navbar-expand-lg bd-navbar" id="navbar-main"><div class="bd-header__inner bd-page-width">
  <label class="sidebar-toggle primary-toggle" for="__primary">
      <span class="fa-solid fa-bars"></span>
  </label>
  <div id="navbar-start">
    
    
  


<a class="navbar-brand logo" href="../index.html">

  
  
  
  
  
  
  

  
    <img src="../_static/networkx_banner.svg" class="logo__image only-light" alt="Logo image">
    <img src="../_static/networkx_banner.svg" class="logo__image only-dark" alt="Logo image">
  
  
</a>
    
  </div>

  
  <div class="col-lg-9 navbar-header-items">
    <div id="navbar-center" class="mr-auto">
      
      <div class="navbar-center-item">
        <nav class="navbar-nav">
    <p class="sidebar-header-items__title" role="heading" aria-level="1" aria-label="Site Navigation">
        Site Navigation
    </p>
    <ul id="navbar-main-elements" class="navbar-nav">
        
                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../install.html">
                        Install
                      </a>
                    </li>
                

                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../tutorial.html">
                        Tutorial
                      </a>
                    </li>
                

                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../reference/index.html">
                        Reference
                      </a>
                    </li>
                

                    <li class="nav-item current active">
                      <a class="nav-link nav-internal" href="#">
                        Gallery
                      </a>
                    </li>
                

                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../developer/index.html">
                        Developer
                      </a>
                    </li>
                

                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../release/index.html">
                        Releases
                      </a>
                    </li>
                

                <li class="nav-item">
                  <a class="nav-link nav-external" href="https://networkx.org/nx-guides/">
                    Guides
                  </a>
                </li>
                
    </ul>
</nav>
      </div>
      
    </div>

    <div id="navbar-end">
      
        <div class="navbar-end-item navbar-persistent--container">
          
<button class="btn btn-sm navbar-btn search-button search-button__button" title="Search" aria-label="Search" data-toggle="tooltip">
  <i class="fa-solid fa-magnifying-glass"></i>
</button>
        </div>
      
      
      <div class="navbar-end-item">
        <button class="theme-switch-button btn btn-sm btn-outline-primary navbar-btn rounded-circle" title="light/dark" aria-label="light/dark" data-toggle="tooltip">
    <span class="theme-switch" data-mode="light"><i class="fa-solid fa-sun"></i></span>
    <span class="theme-switch" data-mode="dark"><i class="fa-solid fa-moon"></i></span>
    <span class="theme-switch" data-mode="auto"><i class="fa-solid fa-circle-half-stroke"></i></span>
</button>
      </div>
      
      <div class="navbar-end-item">
        <ul id="navbar-icon-links" class="navbar-nav" aria-label="Icon Links">
        <li class="nav-item">
          
          
          
          
          
          
          
          <a href="https://networkx.org" title="Home Page" class="nav-link" rel="noopener" target="_blank" data-toggle="tooltip"><span><i class="fas fa-home"></i></span>
            <label class="sr-only">Home Page</label></a>
        </li>
        <li class="nav-item">
          
          
          
          
          
          
          
          <a href="https://github.com/networkx/networkx" title="GitHub" class="nav-link" rel="noopener" target="_blank" data-toggle="tooltip"><span><i class="fab fa-github-square"></i></span>
            <label class="sr-only">GitHub</label></a>
        </li>
      </ul>
      </div>
      
      <div class="navbar-end-item">
        <ul class="navbar-nav">
  <li class="mr-2 dropdown">
    <button
      type="button"
      class="btn btn-version btn-sm navbar-btn dropdown-toggle"
      id="dLabelMore"
      data-toggle="dropdown"
    >
      v3.0rc2.dev0
      <span class="caret"></span>
    </button>
    <ul class="dropdown-menu" aria-labelledby="dLabelMore">
      <li>
        <a href="https://networkx.org/documentation/latest/index.html"
          >devel (latest)</a
        >
      </li>
      <li>
        <a href="https://networkx.org/documentation/stable/index.html"
          >current (stable)</a
        >
      </li>
    </ul>
  </li>
</ul>
      </div>
      
    </div>
  </div>


  
  
    <div class="navbar-persistent--mobile">
<button class="btn btn-sm navbar-btn search-button search-button__button" title="Search" aria-label="Search" data-toggle="tooltip">
  <i class="fa-solid fa-magnifying-glass"></i>
</button>
    </div>
  

  
  <label class="sidebar-toggle secondary-toggle" for="__secondary">
      <span class="fa-solid fa-outdent"></span>
  </label>
  

</div>
  </nav>
  

  <div class="bd-container">
    <div class="bd-container__inner bd-page-width">
      
      <div class="bd-sidebar-primary bd-sidebar hide-on-wide">
        
  
  <div class="sidebar-header-items sidebar-primary__section">
    
    
      <div class="sidebar-header-items__center">
      
      <div class="navbar-center-item">
        <nav class="navbar-nav">
    <p class="sidebar-header-items__title" role="heading" aria-level="1" aria-label="Site Navigation">
        Site Navigation
    </p>
    <ul id="navbar-main-elements" class="navbar-nav">
        
                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../install.html">
                        Install
                      </a>
                    </li>
                

                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../tutorial.html">
                        Tutorial
                      </a>
                    </li>
                

                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../reference/index.html">
                        Reference
                      </a>
                    </li>
                

                    <li class="nav-item current active">
                      <a class="nav-link nav-internal" href="#">
                        Gallery
                      </a>
                    </li>
                

                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../developer/index.html">
                        Developer
                      </a>
                    </li>
                

                    <li class="nav-item">
                      <a class="nav-link nav-internal" href="../release/index.html">
                        Releases
                      </a>
                    </li>
                

                <li class="nav-item">
                  <a class="nav-link nav-external" href="https://networkx.org/nx-guides/">
                    Guides
                  </a>
                </li>
                
    </ul>
</nav>
      </div>
      
      </div>
    

    
    
    <div class="sidebar-header-items__end">
      
      <div class="navbar-end-item">
        <button class="theme-switch-button btn btn-sm btn-outline-primary navbar-btn rounded-circle" title="light/dark" aria-label="light/dark" data-toggle="tooltip">
    <span class="theme-switch" data-mode="light"><i class="fa-solid fa-sun"></i></span>
    <span class="theme-switch" data-mode="dark"><i class="fa-solid fa-moon"></i></span>
    <span class="theme-switch" data-mode="auto"><i class="fa-solid fa-circle-half-stroke"></i></span>
</button>
      </div>
      
      <div class="navbar-end-item">
        <ul id="navbar-icon-links" class="navbar-nav" aria-label="Icon Links">
        <li class="nav-item">
          
          
          
          
          
          
          
          <a href="https://networkx.org" title="Home Page" class="nav-link" rel="noopener" target="_blank" data-toggle="tooltip"><span><i class="fas fa-home"></i></span>
            <label class="sr-only">Home Page</label></a>
        </li>
        <li class="nav-item">
          
          
          
          
          
          
          
          <a href="https://github.com/networkx/networkx" title="GitHub" class="nav-link" rel="noopener" target="_blank" data-toggle="tooltip"><span><i class="fab fa-github-square"></i></span>
            <label class="sr-only">GitHub</label></a>
        </li>
      </ul>
      </div>
      
      <div class="navbar-end-item">
        <ul class="navbar-nav">
  <li class="mr-2 dropdown">
    <button
      type="button"
      class="btn btn-version btn-sm navbar-btn dropdown-toggle"
      id="dLabelMore"
      data-toggle="dropdown"
    >
      v3.0rc2.dev0
      <span class="caret"></span>
    </button>
    <ul class="dropdown-menu" aria-labelledby="dLabelMore">
      <li>
        <a href="https://networkx.org/documentation/latest/index.html"
          >devel (latest)</a
        >
      </li>
      <li>
        <a href="https://networkx.org/documentation/stable/index.html"
          >current (stable)</a
        >
      </li>
    </ul>
  </li>
</ul>
      </div>
      
    </div>
    
  </div>

  

  
  <div class="sidebar-end-items sidebar-primary__section">
    <div class="sidebar-end-items__item">
    </div>
  </div>

  
  <div id="rtd-footer-container"></div>

      </div>
      <main id="main-content" class="bd-main">
        
        
        <div class="bd-content">
          <div class="bd-article-container">
            
            <div class="bd-header-article">
                
            </div>
            
            
            <article class="bd-article" role="main">
              
  <section id="gallery">
<span id="examples-gallery"></span><h1>Gallery<a class="headerlink" href="#gallery" title="Permalink to this heading">#</a></h1>
<p>General-purpose and introductory examples for NetworkX.
The <a class="reference external" href="../tutorial.html">tutorial</a> introduces conventions and basic graph
manipulations.</p>
<div class="sphx-glr-thumbnails"></div><section id="basic">
<h2>Basic<a class="headerlink" href="#basic" title="Permalink to this heading">#</a></h2>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="Compute some network properties for the lollipop graph."><img alt="Properties" src="../_images/sphx_glr_plot_properties_thumb.png" />
<p><a class="reference internal" href="basic/plot_properties.html#sphx-glr-auto-examples-basic-plot-properties-py"><span class="std std-ref">Properties</span></a></p>
  <div class="sphx-glr-thumbnail-title">Properties</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Read and write graphs."><img alt="Read and write graphs." src="../_images/sphx_glr_plot_read_write_thumb.png" />
<p><a class="reference internal" href="basic/plot_read_write.html#sphx-glr-auto-examples-basic-plot-read-write-py"><span class="std std-ref">Read and write graphs.</span></a></p>
  <div class="sphx-glr-thumbnail-title">Read and write graphs.</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Draw simple graph with manual layout."><img alt="Simple graph" src="../_images/sphx_glr_plot_simple_graph_thumb.png" />
<p><a class="reference internal" href="basic/plot_simple_graph.html#sphx-glr-auto-examples-basic-plot-simple-graph-py"><span class="std std-ref">Simple graph</span></a></p>
  <div class="sphx-glr-thumbnail-title">Simple graph</div>
</div></div></section>
<section id="drawing">
<h2>Drawing<a class="headerlink" href="#drawing" title="Permalink to this heading">#</a></h2>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="Draw a graph with node(s) located at user-defined positions."><img alt="Custom Node Position" src="../_images/sphx_glr_plot_center_node_thumb.png" />
<p><a class="reference internal" href="drawing/plot_center_node.html#sphx-glr-auto-examples-drawing-plot-center-node-py"><span class="std std-ref">Custom Node Position</span></a></p>
  <div class="sphx-glr-thumbnail-title">Custom Node Position</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="An example of the MultiDiGraph class."><img alt="Chess Masters" src="../_images/sphx_glr_plot_chess_masters_thumb.png" />
<p><a class="reference internal" href="drawing/plot_chess_masters.html#sphx-glr-auto-examples-drawing-plot-chess-masters-py"><span class="std std-ref">Chess Masters</span></a></p>
  <div class="sphx-glr-thumbnail-title">Chess Masters</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Example of using custom icons to represent nodes with matplotlib."><img alt="Custom node icons" src="../_images/sphx_glr_plot_custom_node_icons_thumb.png" />
<p><a class="reference internal" href="drawing/plot_custom_node_icons.html#sphx-glr-auto-examples-drawing-plot-custom-node-icons-py"><span class="std std-ref">Custom node icons</span></a></p>
  <div class="sphx-glr-thumbnail-title">Custom node icons</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="This example shows several ways to visualize the distribution of the degree of nodes with two c..."><img alt="Degree Analysis" src="../_images/sphx_glr_plot_degree_thumb.png" />
<p><a class="reference internal" href="drawing/plot_degree.html#sphx-glr-auto-examples-drawing-plot-degree-py"><span class="std std-ref">Degree Analysis</span></a></p>
  <div class="sphx-glr-thumbnail-title">Degree Analysis</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Draw a graph with directed edges using a colormap and different node sizes."><img alt="Directed Graph" src="../_images/sphx_glr_plot_directed_thumb.png" />
<p><a class="reference internal" href="drawing/plot_directed.html#sphx-glr-auto-examples-drawing-plot-directed-py"><span class="std std-ref">Directed Graph</span></a></p>
  <div class="sphx-glr-thumbnail-title">Directed Graph</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Draw a graph with matplotlib, color edges."><img alt="Edge Colormap" src="../_images/sphx_glr_plot_edge_colormap_thumb.png" />
<p><a class="reference internal" href="drawing/plot_edge_colormap.html#sphx-glr-auto-examples-drawing-plot-edge-colormap-py"><span class="std std-ref">Edge Colormap</span></a></p>
  <div class="sphx-glr-thumbnail-title">Edge Colormap</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Example using the NetworkX ego_graph() function to return the main egonet of the largest hub in..."><img alt="Ego Graph" src="../_images/sphx_glr_plot_ego_graph_thumb.png" />
<p><a class="reference internal" href="drawing/plot_ego_graph.html#sphx-glr-auto-examples-drawing-plot-ego-graph-py"><span class="std std-ref">Ego Graph</span></a></p>
  <div class="sphx-glr-thumbnail-title">Ego Graph</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Create an G{n,m} random graph and compute the eigenvalues."><img alt="Eigenvalues" src="../_images/sphx_glr_plot_eigenvalues_thumb.png" />
<p><a class="reference internal" href="drawing/plot_eigenvalues.html#sphx-glr-auto-examples-drawing-plot-eigenvalues-py"><span class="std std-ref">Eigenvalues</span></a></p>
  <div class="sphx-glr-thumbnail-title">Eigenvalues</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Draw a 4x4 graph with matplotlib."><img alt="Four Grids" src="../_images/sphx_glr_plot_four_grids_thumb.png" />
<p><a class="reference internal" href="drawing/plot_four_grids.html#sphx-glr-auto-examples-drawing-plot-four-grids-py"><span class="std std-ref">Four Grids</span></a></p>
  <div class="sphx-glr-thumbnail-title">Four Grids</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Draw a graph with matplotlib."><img alt="House With Colors" src="../_images/sphx_glr_plot_house_with_colors_thumb.png" />
<p><a class="reference internal" href="drawing/plot_house_with_colors.html#sphx-glr-auto-examples-drawing-plot-house-with-colors-py"><span class="std std-ref">House With Colors</span></a></p>
  <div class="sphx-glr-thumbnail-title">House With Colors</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="miles_graph() returns an undirected graph over 128 US cities. The cities each have location and..."><img alt="Knuth Miles" src="../_images/sphx_glr_plot_knuth_miles_thumb.png" />
<p><a class="reference internal" href="drawing/plot_knuth_miles.html#sphx-glr-auto-examples-drawing-plot-knuth-miles-py"><span class="std std-ref">Knuth Miles</span></a></p>
  <div class="sphx-glr-thumbnail-title">Knuth Miles</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Use nodelist and edgelist to apply custom coloring and labels to various components of a graph."><img alt="Labels And Colors" src="../_images/sphx_glr_plot_labels_and_colors_thumb.png" />
<p><a class="reference internal" href="drawing/plot_labels_and_colors.html#sphx-glr-auto-examples-drawing-plot-labels-and-colors-py"><span class="std std-ref">Labels And Colors</span></a></p>
  <div class="sphx-glr-thumbnail-title">Labels And Colors</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Multipartite Layout"><img alt="Multipartite Layout" src="../_images/sphx_glr_plot_multipartite_graph_thumb.png" />
<p><a class="reference internal" href="drawing/plot_multipartite_graph.html#sphx-glr-auto-examples-drawing-plot-multipartite-graph-py"><span class="std std-ref">Multipartite Layout</span></a></p>
  <div class="sphx-glr-thumbnail-title">Multipartite Layout</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Draw a graph with matplotlib, color by degree."><img alt="Node Colormap" src="../_images/sphx_glr_plot_node_colormap_thumb.png" />
<p><a class="reference internal" href="drawing/plot_node_colormap.html#sphx-glr-auto-examples-drawing-plot-node-colormap-py"><span class="std std-ref">Node Colormap</span></a></p>
  <div class="sphx-glr-thumbnail-title">Node Colormap</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Generate a complete graph with 13 nodes in a circular layout with the edges colored by node dis..."><img alt="Rainbow Coloring" src="../_images/sphx_glr_plot_rainbow_coloring_thumb.png" />
<p><a class="reference internal" href="drawing/plot_rainbow_coloring.html#sphx-glr-auto-examples-drawing-plot-rainbow-coloring-py"><span class="std std-ref">Rainbow Coloring</span></a></p>
  <div class="sphx-glr-thumbnail-title">Rainbow Coloring</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Example"><img alt="Random Geometric Graph" src="../_images/sphx_glr_plot_random_geometric_graph_thumb.png" />
<p><a class="reference internal" href="drawing/plot_random_geometric_graph.html#sphx-glr-auto-examples-drawing-plot-random-geometric-graph-py"><span class="std std-ref">Random Geometric Graph</span></a></p>
  <div class="sphx-glr-thumbnail-title">Random Geometric Graph</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Sampson&#x27;s monastery data."><img alt="Sampson" src="../_images/sphx_glr_plot_sampson_thumb.png" />
<p><a class="reference internal" href="drawing/plot_sampson.html#sphx-glr-auto-examples-drawing-plot-sampson-py"><span class="std std-ref">Sampson</span></a></p>
  <div class="sphx-glr-thumbnail-title">Sampson</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="A self-loop is an edge that originates from and terminates the same node. This example shows ho..."><img alt="Self-loops" src="../_images/sphx_glr_plot_selfloops_thumb.png" />
<p><a class="reference internal" href="drawing/plot_selfloops.html#sphx-glr-auto-examples-drawing-plot-selfloops-py"><span class="std std-ref">Self-loops</span></a></p>
  <div class="sphx-glr-thumbnail-title">Self-loops</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Draw a graph with matplotlib."><img alt="Simple Path" src="../_images/sphx_glr_plot_simple_path_thumb.png" />
<p><a class="reference internal" href="drawing/plot_simple_path.html#sphx-glr-auto-examples-drawing-plot-simple-path-py"><span class="std std-ref">Simple Path</span></a></p>
  <div class="sphx-glr-thumbnail-title">Simple Path</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="The spectral layout positions the nodes of the graph based on the eigenvectors of the graph Lap..."><img alt="Spectral Embedding" src="../_images/sphx_glr_plot_spectral_grid_thumb.png" />
<p><a class="reference internal" href="drawing/plot_spectral_grid.html#sphx-glr-auto-examples-drawing-plot-spectral-grid-py"><span class="std std-ref">Spectral Embedding</span></a></p>
  <div class="sphx-glr-thumbnail-title">Spectral Embedding</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="This is an example of a drawing solution of the traveling salesman problem"><img alt="Traveling Salesman Problem" src="../_images/sphx_glr_plot_tsp_thumb.png" />
<p><a class="reference internal" href="drawing/plot_tsp.html#sphx-glr-auto-examples-drawing-plot-tsp-py"><span class="std std-ref">Traveling Salesman Problem</span></a></p>
  <div class="sphx-glr-thumbnail-title">Traveling Salesman Problem</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Create a directed graph, allowing multiple edges and self loops, from a unix mailbox.  The node..."><img alt="Unix Email" src="../_images/sphx_glr_plot_unix_email_thumb.png" />
<p><a class="reference internal" href="drawing/plot_unix_email.html#sphx-glr-auto-examples-drawing-plot-unix-email-py"><span class="std std-ref">Unix Email</span></a></p>
  <div class="sphx-glr-thumbnail-title">Unix Email</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="An example using Graph as a weighted network."><img alt="Weighted Graph" src="../_images/sphx_glr_plot_weighted_graph_thumb.png" />
<p><a class="reference internal" href="drawing/plot_weighted_graph.html#sphx-glr-auto-examples-drawing-plot-weighted-graph-py"><span class="std std-ref">Weighted Graph</span></a></p>
  <div class="sphx-glr-thumbnail-title">Weighted Graph</div>
</div></div></section>
<section id="d-drawing">
<h2>3D Drawing<a class="headerlink" href="#d-drawing" title="Permalink to this heading">#</a></h2>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="Mayavi2"><img alt="Mayavi2" src="../_images/sphx_glr_mayavi2_spring_thumb.png" />
<p><a class="reference internal" href="3d_drawing/mayavi2_spring.html#sphx-glr-auto-examples-3d-drawing-mayavi2-spring-py"><span class="std std-ref">Mayavi2</span></a></p>
  <div class="sphx-glr-thumbnail-title">Mayavi2</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="A basic example of 3D Graph visualization using mpl_toolkits.mplot_3d."><img alt="Basic matplotlib" src="../_images/sphx_glr_plot_basic_thumb.png" />
<p><a class="reference internal" href="3d_drawing/plot_basic.html#sphx-glr-auto-examples-3d-drawing-plot-basic-py"><span class="std std-ref">Basic matplotlib</span></a></p>
  <div class="sphx-glr-thumbnail-title">Basic matplotlib</div>
</div></div></section>
<section id="graphviz-layout">
<h2>Graphviz Layout<a class="headerlink" href="#graphviz-layout" title="Permalink to this heading">#</a></h2>
<p>Examples using Graphviz layouts with <a class="reference internal" href="../reference/drawing.html#module-networkx.drawing.nx_pylab" title="networkx.drawing.nx_pylab"><code class="xref py py-obj docutils literal notranslate"><span class="pre">nx_pylab</span></code></a> for drawing.
These examples need Graphviz and <a class="reference external" href="https://pygraphviz.github.io/documentation/stable/index.html" title="(in PyGraphviz v1.10)"><span class="xref std std-doc">PyGraphviz</span></a>.</p>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="Atlas of all connected graphs with up to 6 nodes."><img alt="Atlas" src="../_images/sphx_glr_plot_atlas_thumb.png" />
<p><a class="reference internal" href="graphviz_layout/plot_atlas.html#sphx-glr-auto-examples-graphviz-layout-plot-atlas-py"><span class="std std-ref">Atlas</span></a></p>
  <div class="sphx-glr-thumbnail-title">Atlas</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="This example needs Graphviz and PyGraphviz."><img alt="Circular Tree" src="../_images/sphx_glr_plot_circular_tree_thumb.png" />
<p><a class="reference internal" href="graphviz_layout/plot_circular_tree.html#sphx-glr-auto-examples-graphviz-layout-plot-circular-tree-py"><span class="std std-ref">Circular Tree</span></a></p>
  <div class="sphx-glr-thumbnail-title">Circular Tree</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Example of creating a junction tree from a directed graph."><img alt="Decomposition" src="../_images/sphx_glr_plot_decomposition_thumb.png" />
<p><a class="reference internal" href="graphviz_layout/plot_decomposition.html#sphx-glr-auto-examples-graphviz-layout-plot-decomposition-py"><span class="std std-ref">Decomposition</span></a></p>
  <div class="sphx-glr-thumbnail-title">Decomposition</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="This example illustrates the sudden appearance of a giant connected component in a binomial ran..."><img alt="Giant Component" src="../_images/sphx_glr_plot_giant_component_thumb.png" />
<p><a class="reference internal" href="graphviz_layout/plot_giant_component.html#sphx-glr-auto-examples-graphviz-layout-plot-giant-component-py"><span class="std std-ref">Giant Component</span></a></p>
  <div class="sphx-glr-thumbnail-title">Giant Component</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Routes to LANL from 186 sites on the Internet."><img alt="Lanl Routes" src="../_images/sphx_glr_plot_lanl_routes_thumb.png" />
<p><a class="reference internal" href="graphviz_layout/plot_lanl_routes.html#sphx-glr-auto-examples-graphviz-layout-plot-lanl-routes-py"><span class="std std-ref">Lanl Routes</span></a></p>
  <div class="sphx-glr-thumbnail-title">Lanl Routes</div>
</div></div></section>
<section id="graphviz-drawing">
<h2>Graphviz Drawing<a class="headerlink" href="#graphviz-drawing" title="Permalink to this heading">#</a></h2>
<p>Examples using Graphviz for layout and drawing via <a class="reference internal" href="../reference/drawing.html#module-networkx.drawing.nx_agraph" title="networkx.drawing.nx_agraph"><code class="xref py py-obj docutils literal notranslate"><span class="pre">nx_agraph</span></code></a>.
These examples need Graphviz and <a class="reference external" href="https://pygraphviz.github.io/documentation/stable/index.html" title="(in PyGraphviz v1.10)"><span class="xref std std-doc">PyGraphviz</span></a>.</p>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="Example illustrating how attributes of nodes, edges, and graphs are handled during conversion t..."><img alt="Attributes" src="../_images/sphx_glr_plot_attributes_thumb.png" />
<p><a class="reference internal" href="graphviz_drawing/plot_attributes.html#sphx-glr-auto-examples-graphviz-drawing-plot-attributes-py"><span class="std std-ref">Attributes</span></a></p>
  <div class="sphx-glr-thumbnail-title">Attributes</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="An example showing how to use the interface to the  pygraphviz.AGraph class to convert to and f..."><img alt="Conversion" src="../_images/sphx_glr_plot_conversion_thumb.png" />
<p><a class="reference internal" href="graphviz_drawing/plot_conversion.html#sphx-glr-auto-examples-graphviz-drawing-plot-conversion-py"><span class="std std-ref">Conversion</span></a></p>
  <div class="sphx-glr-thumbnail-title">Conversion</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Illustrate ~networkx.drawing.nx_agraph.write_dot in conjunction with the Graphviz command line ..."><img alt="2D Grid" src="../_images/sphx_glr_plot_grid_thumb.png" />
<p><a class="reference internal" href="graphviz_drawing/plot_grid.html#sphx-glr-auto-examples-graphviz-drawing-plot-grid-py"><span class="std std-ref">2D Grid</span></a></p>
  <div class="sphx-glr-thumbnail-title">2D Grid</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="An example showing how to write first 20 graphs from the graph atlas as graphviz dot files Gn.d..."><img alt="Atlas" src="../_images/sphx_glr_plot_mini_atlas_thumb.png" />
<p><a class="reference internal" href="graphviz_drawing/plot_mini_atlas.html#sphx-glr-auto-examples-graphviz-drawing-plot-mini-atlas-py"><span class="std std-ref">Atlas</span></a></p>
  <div class="sphx-glr-thumbnail-title">Atlas</div>
</div></div></section>
<section id="graph">
<h2>Graph<a class="headerlink" href="#graph" title="Permalink to this heading">#</a></h2>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="This example combines the topological_generations generator with multipartite_layout to show ho..."><img alt="DAG - Topological Layout" src="../_images/sphx_glr_plot_dag_layout_thumb.png" />
<p><a class="reference internal" href="graph/plot_dag_layout.html#sphx-glr-auto-examples-graph-plot-dag-layout-py"><span class="std std-ref">DAG - Topological Layout</span></a></p>
  <div class="sphx-glr-thumbnail-title">DAG - Topological Layout</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Random graph from given degree sequence."><img alt="Degree Sequence" src="../_images/sphx_glr_plot_degree_sequence_thumb.png" />
<p><a class="reference internal" href="graph/plot_degree_sequence.html#sphx-glr-auto-examples-graph-plot-degree-sequence-py"><span class="std std-ref">Degree Sequence</span></a></p>
  <div class="sphx-glr-thumbnail-title">Degree Sequence</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Create an G{n,m} random graph with n nodes and m edges and report some properties."><img alt="Erdos Renyi" src="../_images/sphx_glr_plot_erdos_renyi_thumb.png" />
<p><a class="reference internal" href="graph/plot_erdos_renyi.html#sphx-glr-auto-examples-graph-plot-erdos-renyi-py"><span class="std std-ref">Erdos Renyi</span></a></p>
  <div class="sphx-glr-thumbnail-title">Erdos Renyi</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Random graph from given degree sequence."><img alt="Expected Degree Sequence" src="../_images/sphx_glr_plot_expected_degree_sequence_thumb.png" />
<p><a class="reference internal" href="graph/plot_expected_degree_sequence.html#sphx-glr-auto-examples-graph-plot-expected-degree-sequence-py"><span class="std std-ref">Expected Degree Sequence</span></a></p>
  <div class="sphx-glr-thumbnail-title">Expected Degree Sequence</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Load football network in GML format and compute some network statistcs."><img alt="Football" src="../_images/sphx_glr_plot_football_thumb.png" />
<p><a class="reference internal" href="graph/plot_football.html#sphx-glr-auto-examples-graph-plot-football-py"><span class="std std-ref">Football</span></a></p>
  <div class="sphx-glr-thumbnail-title">Football</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Zachary&#x27;s Karate Club graph"><img alt="Karate Club" src="../_images/sphx_glr_plot_karate_club_thumb.png" />
<p><a class="reference internal" href="graph/plot_karate_club.html#sphx-glr-auto-examples-graph-plot-karate-club-py"><span class="std std-ref">Karate Club</span></a></p>
  <div class="sphx-glr-thumbnail-title">Karate Club</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="A prefix tree (aka a &quot;trie&quot;) representing the Morse encoding of the alphabet. A letter can be e..."><img alt="Morse Trie" src="../_images/sphx_glr_plot_morse_trie_thumb.png" />
<p><a class="reference internal" href="graph/plot_morse_trie.html#sphx-glr-auto-examples-graph-plot-morse-trie-py"><span class="std std-ref">Morse Trie</span></a></p>
  <div class="sphx-glr-thumbnail-title">Morse Trie</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Minard&#x27;s data from Napoleon&#x27;s 1812-1813  Russian Campaign. https://web.archive.org/web/20080112..."><img alt="Napoleon Russian Campaign" src="../_images/sphx_glr_plot_napoleon_russian_campaign_thumb.png" />
<p><a class="reference internal" href="graph/plot_napoleon_russian_campaign.html#sphx-glr-auto-examples-graph-plot-napoleon-russian-campaign-py"><span class="std std-ref">Napoleon Russian Campaign</span></a></p>
  <div class="sphx-glr-thumbnail-title">Napoleon Russian Campaign</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Build a directed graph of 1022 categories and 5075 cross-references as defined in the 1879 vers..."><img alt="Roget" src="../_images/sphx_glr_plot_roget_thumb.png" />
<p><a class="reference internal" href="graph/plot_roget.html#sphx-glr-auto-examples-graph-plot-roget-py"><span class="std std-ref">Roget</span></a></p>
  <div class="sphx-glr-thumbnail-title">Roget</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Triads"><img alt="Triads" src="../_images/sphx_glr_plot_triad_types_thumb.png" />
<p><a class="reference internal" href="graph/plot_triad_types.html#sphx-glr-auto-examples-graph-plot-triad-types-py"><span class="std std-ref">Triads</span></a></p>
  <div class="sphx-glr-thumbnail-title">Triads</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Generate  an undirected graph over the 5757 5-letter words in the datafile words_dat.txt.gz.  T..."><img alt="Words/Ladder Graph" src="../_images/sphx_glr_plot_words_thumb.png" />
<p><a class="reference internal" href="graph/plot_words.html#sphx-glr-auto-examples-graph-plot-words-py"><span class="std std-ref">Words/Ladder Graph</span></a></p>
  <div class="sphx-glr-thumbnail-title">Words/Ladder Graph</div>
</div></div></section>
<section id="algorithms">
<h2>Algorithms<a class="headerlink" href="#algorithms" title="Permalink to this heading">#</a></h2>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="Beam search with dynamic beam width."><img alt="Beam Search" src="../_images/sphx_glr_plot_beam_search_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_beam_search.html#sphx-glr-auto-examples-algorithms-plot-beam-search-py"><span class="std std-ref">Beam Search</span></a></p>
  <div class="sphx-glr-thumbnail-title">Beam Search</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Betweenness centrality measures of positive gene functional associations using WormNet v.3-GS."><img alt="Betweeness Centrality" src="../_images/sphx_glr_plot_betweenness_centrality_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_betweenness_centrality.html#sphx-glr-auto-examples-algorithms-plot-betweenness-centrality-py"><span class="std std-ref">Betweeness Centrality</span></a></p>
  <div class="sphx-glr-thumbnail-title">Betweeness Centrality</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Example of creating a block model using the quotient_graph function in NX.  Data used is the Ha..."><img alt="Blockmodel" src="../_images/sphx_glr_plot_blockmodel_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_blockmodel.html#sphx-glr-auto-examples-algorithms-plot-blockmodel-py"><span class="std std-ref">Blockmodel</span></a></p>
  <div class="sphx-glr-thumbnail-title">Blockmodel</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Convert a Boolean circuit to an equivalent Boolean formula."><img alt="Circuits" src="../_images/sphx_glr_plot_circuits_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_circuits.html#sphx-glr-auto-examples-algorithms-plot-circuits-py"><span class="std std-ref">Circuits</span></a></p>
  <div class="sphx-glr-thumbnail-title">Circuits</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Davis Southern Club Women"><img alt="Davis Club" src="../_images/sphx_glr_plot_davis_club_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_davis_club.html#sphx-glr-auto-examples-algorithms-plot-davis-club-py"><span class="std std-ref">Davis Club</span></a></p>
  <div class="sphx-glr-thumbnail-title">Davis Club</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Examples of dedensification of a graph.  Dedensification retains the structural pattern of the ..."><img alt="Dedensification" src="../_images/sphx_glr_plot_dedensification_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_dedensification.html#sphx-glr-auto-examples-algorithms-plot-dedensification-py"><span class="std std-ref">Dedensification</span></a></p>
  <div class="sphx-glr-thumbnail-title">Dedensification</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Digraphs from Integer-valued Iterated Functions"><img alt="Iterated Dynamical Systems" src="../_images/sphx_glr_plot_iterated_dynamical_systems_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_iterated_dynamical_systems.html#sphx-glr-auto-examples-algorithms-plot-iterated-dynamical-systems-py"><span class="std std-ref">Iterated Dynamical Systems</span></a></p>
  <div class="sphx-glr-thumbnail-title">Iterated Dynamical Systems</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Centrality measures of Krackhardt social network."><img alt="Krackhardt Centrality" src="../_images/sphx_glr_plot_krackhardt_centrality_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_krackhardt_centrality.html#sphx-glr-auto-examples-algorithms-plot-krackhardt-centrality-py"><span class="std std-ref">Krackhardt Centrality</span></a></p>
  <div class="sphx-glr-thumbnail-title">Krackhardt Centrality</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Example of parallel implementation of betweenness centrality using the multiprocessing module f..."><img alt="Parallel Betweenness" src="../_images/sphx_glr_plot_parallel_betweenness_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_parallel_betweenness.html#sphx-glr-auto-examples-algorithms-plot-parallel-betweenness-py"><span class="std std-ref">Parallel Betweenness</span></a></p>
  <div class="sphx-glr-thumbnail-title">Parallel Betweenness</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Cuthill-McKee ordering of matrices"><img alt="Reverse Cuthill--McKee" src="../_images/sphx_glr_plot_rcm_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_rcm.html#sphx-glr-auto-examples-algorithms-plot-rcm-py"><span class="std std-ref">Reverse Cuthill–McKee</span></a></p>
  <div class="sphx-glr-thumbnail-title">Reverse Cuthill--McKee</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="SNAP Graph Summary"><img alt="SNAP Graph Summary" src="../_images/sphx_glr_plot_snap_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_snap.html#sphx-glr-auto-examples-algorithms-plot-snap-py"><span class="std std-ref">SNAP Graph Summary</span></a></p>
  <div class="sphx-glr-thumbnail-title">SNAP Graph Summary</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Subgraphs"><img alt="Subgraphs" src="../_images/sphx_glr_plot_subgraphs_thumb.png" />
<p><a class="reference internal" href="algorithms/plot_subgraphs.html#sphx-glr-auto-examples-algorithms-plot-subgraphs-py"><span class="std std-ref">Subgraphs</span></a></p>
  <div class="sphx-glr-thumbnail-title">Subgraphs</div>
</div></div></section>
<section id="external-libraries">
<h2>External libraries<a class="headerlink" href="#external-libraries" title="Permalink to this heading">#</a></h2>
<p>Examples of using NetworkX with external libraries.</p>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="Example of writing JSON format graph data and using the D3 Javascript library to produce an HTM..."><img alt="Javascript" src="../_images/sphx_glr_javascript_force_thumb.png" />
<p><a class="reference internal" href="external/javascript_force.html#sphx-glr-auto-examples-external-javascript-force-py"><span class="std std-ref">Javascript</span></a></p>
  <div class="sphx-glr-thumbnail-title">Javascript</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="igraph (https://igraph.org/) is a popular network analysis package that provides (among many ot..."><img alt="igraph" src="../_images/sphx_glr_plot_igraph_thumb.png" />
<p><a class="reference internal" href="external/plot_igraph.html#sphx-glr-auto-examples-external-plot-igraph-py"><span class="std std-ref">igraph</span></a></p>
  <div class="sphx-glr-thumbnail-title">igraph</div>
</div></div></section>
<section id="geospatial">
<h2>Geospatial<a class="headerlink" href="#geospatial" title="Permalink to this heading">#</a></h2>
<p>The following geospatial examples showcase different ways of performing
network analyses using packages within the geospatial Python ecosystem.
Example spatial files are stored directly in this directory.
See the <a class="reference external" href="geospatial/extended_description.html">extended description</a> for more details.</p>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="This example shows how to build a delaunay graph (plus its dual, the set of Voronoi polygons) f..."><img alt="Delaunay graphs from geographic points" src="../_images/sphx_glr_plot_delaunay_thumb.png" />
<p><a class="reference internal" href="geospatial/plot_delaunay.html#sphx-glr-auto-examples-geospatial-plot-delaunay-py"><span class="std std-ref">Delaunay graphs from geographic points</span></a></p>
  <div class="sphx-glr-thumbnail-title">Delaunay graphs from geographic points</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="This example shows how to build a graph from a set of geographic lines (sometimes called &quot;lines..."><img alt="Graphs from a set of lines" src="../_images/sphx_glr_plot_lines_thumb.png" />
<p><a class="reference internal" href="geospatial/plot_lines.html#sphx-glr-auto-examples-geospatial-plot-lines-py"><span class="std std-ref">Graphs from a set of lines</span></a></p>
  <div class="sphx-glr-thumbnail-title">Graphs from a set of lines</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="This example shows how to use OSMnx to download and model a street network from OpenStreetMap, ..."><img alt="OpenStreetMap with OSMnx" src="../_images/sphx_glr_plot_osmnx_thumb.png" />
<p><a class="reference internal" href="geospatial/plot_osmnx.html#sphx-glr-auto-examples-geospatial-plot-osmnx-py"><span class="std std-ref">OpenStreetMap with OSMnx</span></a></p>
  <div class="sphx-glr-thumbnail-title">OpenStreetMap with OSMnx</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="This example shows how to build a graph from a set of points using PySAL and geopandas. In this..."><img alt="Graphs from geographic points" src="../_images/sphx_glr_plot_points_thumb.png" />
<p><a class="reference internal" href="geospatial/plot_points.html#sphx-glr-auto-examples-geospatial-plot-points-py"><span class="std std-ref">Graphs from geographic points</span></a></p>
  <div class="sphx-glr-thumbnail-title">Graphs from geographic points</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="This example shows how to build a graph from a set of polygons using PySAL and geopandas. We&#x27;ll..."><img alt="Graphs from Polygons" src="../_images/sphx_glr_plot_polygons_thumb.png" />
<p><a class="reference internal" href="geospatial/plot_polygons.html#sphx-glr-auto-examples-geospatial-plot-polygons-py"><span class="std std-ref">Graphs from Polygons</span></a></p>
  <div class="sphx-glr-thumbnail-title">Graphs from Polygons</div>
</div></div></section>
<section id="subclass">
<h2>Subclass<a class="headerlink" href="#subclass" title="Permalink to this heading">#</a></h2>
<div class="sphx-glr-thumbnails"><div class="sphx-glr-thumbcontainer" tooltip="Complement graph class for small footprint when working on dense graphs."><img alt="Antigraph" src="../_images/sphx_glr_plot_antigraph_thumb.png" />
<p><a class="reference internal" href="subclass/plot_antigraph.html#sphx-glr-auto-examples-subclass-plot-antigraph-py"><span class="std std-ref">Antigraph</span></a></p>
  <div class="sphx-glr-thumbnail-title">Antigraph</div>
</div><div class="sphx-glr-thumbcontainer" tooltip="Example subclass of the Graph class."><img alt="Print Graph" src="../_images/sphx_glr_plot_printgraph_thumb.png" />
<p><a class="reference internal" href="subclass/plot_printgraph.html#sphx-glr-auto-examples-subclass-plot-printgraph-py"><span class="std std-ref">Print Graph</span></a></p>
  <div class="sphx-glr-thumbnail-title">Print Graph</div>
</div></div><div class="toctree-wrapper compound">
</div>
<div class="sphx-glr-footer sphx-glr-footer-gallery docutils container">
<div class="sphx-glr-download sphx-glr-download-python docutils container">
<p><a class="reference download internal" download="" href="../_downloads/07fcc19ba03226cd3d83d4e40ec44385/auto_examples_python.zip"><code class="xref download docutils literal notranslate"><span class="pre">Download</span> <span class="pre">all</span> <span class="pre">examples</span> <span class="pre">in</span> <span class="pre">Python</span> <span class="pre">source</span> <span class="pre">code:</span> <span class="pre">auto_examples_python.zip</span></code></a></p>
</div>
<div class="sphx-glr-download sphx-glr-download-jupyter docutils container">
<p><a class="reference download internal" download="" href="../_downloads/6f1e7a639e0699d6164445b55e6c116d/auto_examples_jupyter.zip"><code class="xref download docutils literal notranslate"><span class="pre">Download</span> <span class="pre">all</span> <span class="pre">examples</span> <span class="pre">in</span> <span class="pre">Jupyter</span> <span class="pre">notebooks:</span> <span class="pre">auto_examples_jupyter.zip</span></code></a></p>
</div>
</div>
<p class="sphx-glr-signature"><a class="reference external" href="https://sphinx-gallery.github.io">Gallery generated by Sphinx-Gallery</a></p>
</section>
</section>


            </article>
            
            
            
          </div>
          
          
          
            <div class="bd-sidebar-secondary bd-toc">
              
<div class="toc-item">
  
<div class="tocsection onthispage">
    <i class="fa-solid fa-list"></i> On this page
</div>
<nav id="bd-toc-nav" class="page-toc">
    <ul class="visible nav section-nav flex-column">
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#basic">
   Basic
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#drawing">
   Drawing
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#d-drawing">
   3D Drawing
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#graphviz-layout">
   Graphviz Layout
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#graphviz-drawing">
   Graphviz Drawing
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#graph">
   Graph
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#algorithms">
   Algorithms
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#external-libraries">
   External libraries
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#geospatial">
   Geospatial
  </a>
 </li>
 <li class="toc-h2 nav-item toc-entry">
  <a class="reference internal nav-link" href="#subclass">
   Subclass
  </a>
 </li>
</ul>

</nav>
</div>

<div class="toc-item">
  
<div id="searchbox"></div>
</div>

<div class="toc-item">
  
</div>

<div class="toc-item">
  
</div>

            </div>
          
          
        </div>
        <footer class="bd-footer-content">
          <div class="bd-footer-content__inner">
            
          </div>
        </footer>
        
      </main>
    </div>
  </div>

  
    
  <!-- Scripts loaded after <body> so the DOM is not blocked -->
  <script src="../_static/scripts/bootstrap.js?digest=796348d33e8b1d947c94"></script>
<script src="../_static/scripts/pydata-sphinx-theme.js?digest=796348d33e8b1d947c94"></script>
 
  <footer class="bd-footer"><div class="bd-footer__inner container">
  
  <div class="footer-item">
    
<p class="copyright">

    &copy; Copyright 2004-2023, NetworkX Developers.<br>

</p>

  </div>
  
  <div class="footer-item">
    <p class="theme-version">
    Built with the
    <a href="https://pydata-sphinx-theme.readthedocs.io/en/stable/index.html">
        PyData Sphinx Theme
    </a>
    0.12.0.
</p>
  </div>
  
  <div class="footer-item">
    
<p class="sphinx-version">
Created using <a href="http://sphinx-doc.org/">Sphinx</a> 5.2.3.<br>
</p>

  </div>
  
</div>
  </footer>
  </body>
</html>