summaryrefslogtreecommitdiff
path: root/examples
Commit message (Collapse)AuthorAgeFilesLines
...
* Deprecate jit (#4428)Jarrod Millman2020-12-101-37/+0
| | | | | * Remove example * Deprecate jit_graph / jit_data
* Update geospatial readme (#4417)Jarrod Millman2020-12-082-0/+69
| | | | | | | | | | | Co-authored-by: Brendan Ward <bcward@astutespruce.com> Co-authored-by: Martin Fleischmann <martin@martinfleischmann.net> Co-authored-by: Geoff Boeing <gboeing@users.noreply.github.com> Co-authored-by: Ross Barnowski <rossbar@berkeley.edu> Co-authored-by: Brendan Ward <bcward@astutespruce.com> Co-authored-by: Martin Fleischmann <martin@martinfleischmann.net> Co-authored-by: Geoff Boeing <gboeing@users.noreply.github.com> Co-authored-by: Ross Barnowski <rossbar@berkeley.edu>
* Collect graphviz examples (#4427)Jarrod Millman2020-12-078-3/+7
| | | | | | | * Collect graphviz examples * Sort examples by file name * Improve graphviz gallery layout
* Add igraph example (#4404)Jarrod Millman2020-12-071-0/+44
| | | | | * Add igraph example * Update comment to mention upcoming igraph release
* Add gallery example for drawing self-loops. (#4430)Ross Barnowski2020-12-071-0/+29
|
* Remove advanced example section (#4429)Jarrod Millman2020-12-065-56/+0
|
* Refactor gallery (#4422)Jarrod Millman2020-12-0631-208/+146
| | | | | | | | | | | | | | | * Add external directory * Move Javascript and JIT * Remove application section * Consolidate and move pygraphviz examples * Clean up imports * Reorder * Fix subclass examples
* Add plotting examples for geospatial data (#4366)Levi John Wolf2020-12-0312-0/+856
| | | | | Co-authored-by: Levi John Wolf <leviwolf@it036330.home> Co-authored-by: Ross Barnowski <rossbar@berkeley.edu> Co-authored-by: Jarrod Millman <jarrod.millman@gmail.com>
* DOC: geospatial example using lines (#4407)Martin Fleischmann2020-12-034-43/+138
| | | | | | | | | | | | | | | | | | | | | | | | | | * DOC: geospatial example using lines * convert dual back * attribution * requirements * try to fix rasterio * use libpysal * cleanup temp examples * Fix typos * Apply suggestions from code review Co-authored-by: Ross Barnowski <rossbar@berkeley.edu> * remove plt.show Co-authored-by: Jarrod Millman <jarrod.millman@gmail.com> Co-authored-by: Ross Barnowski <rossbar@berkeley.edu>
* Use str dunder (#4412)Jarrod Millman2020-12-035-7/+5
|
* Add plot for rcm example (#4411)Jarrod Millman2020-12-031-4/+10
|
* Add words graph plot (#4409)Jarrod Millman2020-12-021-2/+20
|
* Add circuit plot (#4408)Jarrod Millman2020-12-021-11/+27
|
* Don't import nx from networkx (#4403)Jarrod Millman2020-12-014-4/+4
|
* Add gene-gene network (#4269)Jarrod Millman2020-11-242-0/+78819
|
* add OSMnx example (#4383)Geoff Boeing2020-11-241-7/+39
|
* Enable mayavi in sphinx gallery. (#4297)Ross Barnowski2020-11-141-2/+4
| | | | | | | | | | | | | | | | | | * Enable mayavi in sphinx gallery. * Add mayavi deps to example requirements. * Install vtk before mayavi * Don't popup Mayavi windows * Display offscreen * Borrow mayavi CI conf from sphinx-gallery * Grab dependencies as specified in sphinx-gallery conf. * Set up virtual frame buffer so mayavi can import/run headless. Co-authored-by: Jarrod Millman <jarrod.millman@gmail.com>
* Deprecate nx_shp (#4298)Jarrod Millman2020-11-134-0/+62
| | | | | | | * Deprecate nx_shp * Add geospatial example stubs * Add link to gallery
* Update adjacency_iter to adjacency (#4339)Jon Crall2020-11-121-4/+4
| | | | | | | | | | | | | * Update adjacency_iter to adjacency * Use faster adj * wip * Update plot_antigraph.py Remove benchmark * wip
* Sphinx33 (#4342)Jarrod Millman2020-11-122-5/+5
| | | | | * Update sphinx * Cleanup sphinx warnings
* Add rainbow coloring example to gallery. (#4330)Ross Barnowski2020-11-121-0/+68
| | | | | | | | | | | | | | * Add rainbow coloring example to gallery. Adds an example where edges on a complete graph are colored by node distance. * Update cycle fn param name. * Update description and add link to article. Co-authored-by: Jon Crall <erotemic@gmail.com> Co-authored-by: Jon Crall <erotemic@gmail.com>
* adds dedensification function (#4240)Douglas Fenstermacher2020-11-091-0/+93
| | | | | | | * adds dedensification function, documentation, and examples * rm unnecessary lines. Co-authored-by: Ross Barnowski <rossbar@berkeley.edu>
* Add simple graph w/ manual layout (#4291)Jarrod Millman2020-10-261-0/+60
| | | | | | | * Draw simple graph w/ manual layout * Add example from Dan * Move per Ross suggestion
* Update homepage URL (#4285)Jarrod Millman2020-10-251-1/+1
| | | | | | | | | * Update homepage URL * Using Ross's suggestion from PR #4258 * Use https * Fix NXEP link
* Improve axes layout in plot_decomposition example (#4278)Ross Barnowski2020-10-241-10/+12
| | | | | | | * Fix axis layout and padding for decomposition fig. * More vertical aspect ratio. * Remove unnecessary imports.
* Add a 3D plotting example with matplotlib to the gallery (#4268)Ross Barnowski2020-10-241-0/+51
| | | | | | | | | * Add a 3D drawing example using matplotlib Based on the mayavi example, but using mpl_toolkits.mplot3d instead. * Rename to get sphinx gallery to pick up file * Change title.
* Add seeds to gallery examples for reproducibility (#4276)Ross Barnowski2020-10-2422-34/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Seed layout basic/plot_properties. * Seed simple path example * Switch node cmap example to deterministic layout * Seed layout in edge_colormap example * Seed graph gen and layout in ego_graph example * Seed random_geometric_graph example. * Seed layout and pad axes w/ tight_layout. * Seed and modify colors for directed example. * Seeded graph gen and layout * Switch to plasma colormap for better contrast on light bgnd * Seed layout and tight_layout sampson example * Seed and pad axes for unix email example * Seed graph gen and layout for erdos_renyi example * Seed graph gen and layout of degree_seq example * Seed layout of football example * Seed layout for krackhardt centrality example * Seed davis club example * Seed and use np alias in blockmodel example * Seed beam search example. * Seed random graph in eigenval example * Seed heavy metal layout and pad axes * Use deterministic layout for rgraph example * Seed layout for printgraph example. * Add seed to antigraph example. * Use single rng seed value. For examples with multiple uses of rng's (e.g. one for generating a random graph, and another for layout) use a single integer value as the seed for both. * Remove unnecessary submodule paths from examples.
* Improve readibility of chess_example in gallery (#4252)Ross Barnowski2020-10-161-42/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * WIP: Improve visualization. * Switch layout (kamada_kawaii) * Move legend and change font color * Manual axes lim and tight_layout * DOC: Minor changes to wording of example. * ENH: Switch reading bzip to context manager. * MAINT: simplify print statements and use fstrings * MAINT: listcomp to simplify loops. * ENH: tweaks to visualization. * MAINT: rm gca for ax instance * Remove thin edge lines. * Change node color. * Manual reposition to reduce label collision * Switch axis scaling to margins from xlim * Darker nodes with bbox labels.
* Improve legibility of labels in plot_labels_and_colors example (#4266)Ross Barnowski2020-10-161-8/+10
| | | | | | | | | | | | * Improve legibility of labels by: * Increasing background alpha * Increasing font size * Changing to a light font color to contrast with the r/b bgnds * Set seed for reproducible layout. * Switch to tableau colorscheme * Update docstring.
* Update "four_grids" gallery example (#4264)Ross Barnowski2020-10-161-15/+38
| | | | | | | | | | | | | * Add a slightly more descriptive introduction. * Use subplots to show populating axes individually. * Prevent node clipping with axes margins. * Switch color scheme to tableau * Add seed for reproducible layout. * Apply comments from code review
* Update Knuth miles example. (#4251)Ross Barnowski2020-10-161-17/+63
| | | | | | | | | | | | | | | | | | | | | | | | * MAINT: replace hard-coded print with print(G). Take advantage of more descriptive G.__str__. * WIP: get example working with cartopy * WIP: Make knuth example work with or without cartopy * CI: cherrypick CI setup from #4250 * Add country boundaries to knuth example. Adds Canada and Mexico map boundaries so that the Canadian cities are not floating in negative space * Slightly better figure aspect. * Reduce linewidth for paths between cities. Provides a little more contrast with the map borders. * Add warnings filter to ignore cartopy warnings
* Replace degree_histogram and degree_rank with a single example (#4265)Ross Barnowski2020-10-163-64/+50
| | | | | | | | | | | | | | | * Add rank plot and degree hist in one figure Condense the degree histogram and degree rank plot examples into a single example where the visualization inclues three things: 1. The subgraph of connected components 2. The degree rank plot 3. The degree histogram * Rename example and remove deg hist example. * Add summary of example to docstring and rename * Seeded graph gen and layout for reproduciblity.
* Update "house with colors" gallery example (#4263)Ross Barnowski2020-10-161-2/+9
| | | | | | | * Fix axes so that nodes are fully contained in figure. * Change node color scheme. * Switch to tableau color scheme
* Update giant component example (#4267)Ross Barnowski2020-10-161-17/+21
| | | | | | | | | | | | | | | * Update comment section about dependencies. Use try except. * Switch from plt to fig,ax approach for subplots * De-emphasize non-connected nodes in visualization * Make nodes more visible and refactor code * Seed example and remove layout try/except Co-authored-by: Jarrod Millman <jarrod.millman@gmail.com>
* Use seed to make plot fixed (#4260)Jarrod Millman2020-10-161-1/+2
|
* Format w/ black==20.8b1Jarrod Millman2020-10-066-9/+12
|
* Docs update (#4161)Dan Schult2020-08-161-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Fixes #3955 (boundary_expansion docs) * add to docs for steiner_tree * Add missing functions to docs. Thanks to #4111 * Doc fixups * Put filters onto the doc pages. * Add @jamestrimble doc compare script to repo and expand * Fix latex syntax in docs for trophic * more latex corrections * deprecate edge_betweeness and betweeness_centrality_source. warnings and add to list of deprecations * Use docs to identify hopcrfot_karo_matching and maximum_matching * remove underscore from _naive_greedy_modularity_communities * cite James Trimble for code that finds missing functions * Update parallel_betweenness example to avoid deprecated function betweenness_centrality_source should be replaced by betweenness_centrality_subset in plot_parallel_betweenness. find _naive_greedy and change name * tweak
* junction_tree for #1012 (#4004)Matthias Bruhns2020-08-151-0/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Initial commit. * Fixed PEP 8 issues. * Fixed more PEP 8 issues. * Added type to sepset-nodes. * Moved file to networkx/algorithms/tree, changed name of module to avoid namespace collision, added entry to doc system, changed deepcopy to list, removed check for None, shifted to G.is_directed(), added example. * Removed example code. * Removed unused import statement. * Moved notes section. * Fixed PEP 8 issues and removed old file. * Fixed PEP 8 issues. * Formatting with Black, added docstring to example and removed license information. * Added name to name of contributors. * Ran black i.e., black networkx/algorithms/tree/tests/test_junction_tree_algorithm.py * Updated explanation of junction trees, removed 'Graph' from unsupported classes. * DOC: tweaks to docstring. * Changed naming and updated docstring/code according to suggestions. * Removed old files. * Updated doc and init. * Minor tweaks in docs and import structure * Improve example Co-authored-by: Jarrod Millman <jarrod.millman@gmail.com> Co-authored-by: Ross Barnowski <rossbar@berkeley.edu> Co-authored-by: Dan Schult <dschult@colgate.edu>
* Format w/ blackJarrod Millman2020-07-103-17/+17
|
* Ran pyupgrade --py36plusJarrod Millman2020-07-101-1/+1
|
* Implemented multipartite_layout (#3815)Jose Pinilla2020-07-101-0/+39
| | | | | | | | | | | | | * Implemented multipartite_layout * Added test. * Remove left over `max_layer` in multipartite_layout * Multipartite Layout Example * Update examples/drawing/plot_multipartite_graph.py Co-authored-by: Jarrod Millman <jarrod.millman@gmail.com>
* Make gallery more prominentJarrod Millman2020-07-071-2/+2
|
* Handle kwds explicitly in draw_networkx (#4033)Jeremias Traub2020-07-055-6/+4
| | | | | | | * Handle kwds explicitly in draw_networkx; fix kwds in examples * fix PEP8 issues Fixes #4020
* Fix exception causes and messages in 12 modules (#4012)Ram Rachum2020-06-221-2/+2
| | | | | | | * Fix exception causes and messages in 12 modules * Remove deprecated matplotlib.use(warn=False) that was default anyway. Co-authored-by: Dan Schult <dschult@colgate.edu>
* Upgrade to Py36 syntaxJarrod Millman2020-01-016-13/+12
| | | | $ find examples -name \*.py -exec pyupgrade --py36-plus {} \;
* Link to files needed for example (#3752)Jarrod Millman2019-12-171-0/+4
|
* Add links to data filesJarrod Millman2019-11-1616-152/+89
|
* Update examplesJarrod Millman2019-11-1150-985/+688
|
* Add back to galleryJarrod Millman2019-10-291-5/+4
|
* Remove shim that worked around using starmapStefan van der Walt2019-10-291-14/+5
|