iplotx 1.6.0__tar.gz → 1.7.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {iplotx-1.6.0 → iplotx-1.7.0}/PKG-INFO +5 -5
- {iplotx-1.6.0 → iplotx-1.7.0}/README.md +3 -3
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/api/complete_style_specification.md +12 -2
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/installing.md +8 -2
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/sg_execution_times.rst +14 -5
- iplotx-1.7.0/gallery/GALLERY_HEADER.rst +34 -0
- iplotx-1.7.0/gallery/fun/GALLERY_HEADER.rst +2 -0
- iplotx-1.7.0/gallery/fun/plot_67.py +54 -0
- iplotx-1.7.0/gallery/other/plot_hover_neighborhood.py +83 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_mouse_hover.py +1 -1
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_curved_waypoints.py +4 -4
- iplotx-1.7.0/gallery/style/plot_edge_multicolor.py +29 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_waypoints.py +0 -4
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/plotting.py +47 -4
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/utils/matplotlib.py +5 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/version.py +1 -1
- {iplotx-1.6.0 → iplotx-1.7.0}/pyproject.toml +1 -1
- iplotx-1.7.0/tests/baseline_images/test_networkx/triangular_lattice.png +0 -0
- iplotx-1.7.0/tests/test_igraph.py +367 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_networkx.py +8 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/uv.lock +2 -37
- iplotx-1.6.0/gallery/GALLERY_HEADER.rst +0 -2
- iplotx-1.6.0/tests/test_igraph.py +0 -385
- {iplotx-1.6.0 → iplotx-1.7.0}/.github/workflows/publish.yml +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/.github/workflows/test.yml +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/.gitignore +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/.pre-commit-config.yaml +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/.readthedocs.yaml +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/LICENSE +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/MANIFEST.in +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/assets/pylint.svg +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/Makefile +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/make.bat +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/_static/banner.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/_static/custom-icons.js +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/_static/custom.css +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/_static/graph_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/_templates/layout.html +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/api/artists.md +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/api/plotting.md +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/api/providers.md +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/api/style.md +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/api.md +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/code_of_conduct.rst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/conf.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/images/sphx_glr_plot_basic_001.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/images/thumb/sphx_glr_plot_basic_thumb.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/index.md +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/providers.md +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/docs/source/style.md +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/GALLERY_HEADER.rst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_3d.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_arcs.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_basic.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_big_curves.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_dag.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_directed.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_grouping.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_house.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_loops.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/basic/plot_simple_path.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/GALLERY_HEADER.rst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/data/80201010000000001.mst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/data/GN-tree.json +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/data/breast_cancer_string_interactions_short.tsv +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/data/breast_cancer_string_network_coordinates.tsv +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/data/cell_cycle_arrest_string_interactions_short.tsv +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/data/cell_cycle_arrest_string_network_coordinates.tsv +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/data/fevo-08-588430_DataSheet1_S1.csv +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_animal_phylogeny.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_antibody_clone.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_breast_cancer_ppi.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_cell_cycle_arrest.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_food_network.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_foraging_table.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_pollinators.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_ppi.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/biology/plot_tca_cycle.py +0 -0
- {iplotx-1.6.0/gallery/other → iplotx-1.7.0/gallery/fun}/plot_train.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/GALLERY_HEADER.rst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/data/chess_masters_WCC.pgn.bz2 +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/data/knuth_miles.txt.gz +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_arrowlawn.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_chess_masters.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_cliques.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_cluster_layout.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_company_structure.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_complex.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_financial_network.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_knuth_miles.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_labels_and_colors.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_max_bipartite_matching.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_minimum_spanning_trees.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_multipartite_layout.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_parallel_igraph_networkx.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_redblack.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_shortest_path.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_simple_networkx.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_social_network_circles.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_traveling_salesman.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/network_science/plot_with_colorbar.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/GALLERY_HEADER.rst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/data/african_cities_coords.csv +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/data/draco_stars.csv +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_animation.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_bundles.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_constellation.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_edit_artists.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_feedbacks.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_geomap.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_graph.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/other/plot_multiarc.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/GALLERY_HEADER.rst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_arrows.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_custom_vertex.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_depthshade.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_edge_geometries.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_edgepadding.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_elements.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_filled_edges.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_four_grids.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_halfarrows.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_multistyle.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_ports.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_style.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_tension.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_vertexmarkers.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/style/plot_voronoi.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/GALLERY_HEADER.rst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/data/tree-with-support.json +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_angular_waypoints.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_biopython_tree.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_cladeedges.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_cogent3_layouts.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_cogent3_tree.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_dendropy.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_double_tree.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_elements_tree.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_equalangle.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_ete4.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_leafedges.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_leafedges_and_cascades.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_scalebar.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_skbio_tree.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_split_edges.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_style_tree.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_support.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_tree_node_background.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_tree_style_clades.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/tree/plot_trees_of_trees.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/zero_dependency/GALLERY_HEADER.rst +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/zero_dependency/plot_simplenetworkdataprovider.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/gallery/zero_dependency/plot_simpletreedataprovider.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/art3d/edge/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/art3d/edge/arrow.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/art3d/edge/geometry.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/art3d/vertex.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/artists.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/edge/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/edge/arrow.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/edge/geometry.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/edge/leaf.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/edge/ports.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/heuristics.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/network/graph_tool.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/network/igraph.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/network/networkx.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/network/simple.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/tree/biopython.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/tree/cogent3.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/tree/dendropy.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/tree/ete4.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/tree/simple.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/providers/tree/skbio.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/ingest/typing.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/label.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/layout/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/layout/tree/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/layout/tree/rooted.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/layout/tree/unrooted.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/network/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/network/groups.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/style/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/style/leaf_info.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/style/library.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/tree/__init__.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/tree/cascades.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/tree/scalebar.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/typing.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/utils/geometry.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/utils/internal.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/utils/style.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/iplotx/vertex.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/scripts/copy_github_release_into_version.sh +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/scripts/make_banner.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/scripts/update_pylint_badge.sh +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_biopython/cascades.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_biopython/directed_child.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_biopython/leaf_labels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_biopython/leaf_labels_hmargin.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_biopython/leafedges.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_biopython/show_support.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_biopython/tree_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_biopython/tree_radial.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_cogent3/leaf_labels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_cogent3/leaf_labels_hmargin.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_cogent3/tree_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_cogent3/tree_radial.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_dendropy/cascades.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_dendropy/directed_child.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_dendropy/leaf_labels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_dendropy/leaf_labels_hmargin.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_dendropy/leafedges.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_dendropy/tree_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_dendropy/tree_radial.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_doubletree/tree_gap.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_doubletree/tree_nogap.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_ete4/equalangle_layout.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_ete4/leaf_labels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_ete4/leaf_labels_hmargin.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_ete4/split_edges.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_ete4/tree_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_ete4/tree_radial.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_graph_tool/graph_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_graph_tool/graph_directed.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/arcs.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/clustering_directed.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/clustering_directed_large.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/directed_arcs.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_directed.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_directed_curved_loops.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_edit_children.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_labels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_layout_attribute.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_null.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_squares_directed.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_vertexsize.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/graph_with_curved_edges.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/igraph_layout_object.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/large_arcs.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/multiarc45.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph/multigraph_with_curved_edges_undirected.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph_3d/directed.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph_3d/undirected.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_igraph_3d/vertex_labels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/cluster-layout.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/complex.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/complex_rotatelabels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/custom_marker_path.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/custom_marker_polygon.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/directed_graph.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/directed_graph_with_colorbar.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/empty_graph.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/flat_style.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/house_with_colors.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/labels_and_colors.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/shortest_path.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_networkx/simple_graph.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_simple_network_provider/curved_waypoints.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_simple_network_provider/graph_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_simple_network_provider/graph_directed.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_simple_network_provider/graph_labels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_skbio/leaf_labels.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_skbio/leaf_labels_hmargin.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_skbio/tree_basic.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/baseline_images/test_skbio/tree_radial.png +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_arrows.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_biopython.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_cascades.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_cogent3.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_dendropy.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_doubletree.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_edge.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_edge_geometry.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_ete4.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_geometry.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_graph_tool.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_heuristics.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_igraph_3d.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_ingest_protocols.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_matplotlib_utils.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_network_hotload.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_ports.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_simple_network_provider.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_simple_tree_provider.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_skbio.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_style.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/test_vertex.py +0 -0
- {iplotx-1.6.0 → iplotx-1.7.0}/tests/utils.py +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: iplotx
|
|
3
|
-
Version: 1.
|
|
4
|
-
Summary:
|
|
3
|
+
Version: 1.7.0
|
|
4
|
+
Summary: Universal network and tree visualisation library.
|
|
5
5
|
Project-URL: Homepage, https://github.com/fabilab/iplotx
|
|
6
6
|
Project-URL: Documentation, https://readthedocs.org/iplotx
|
|
7
7
|
Project-URL: Repository, https://github.com/fabilab/iplotx.git
|
|
@@ -41,7 +41,7 @@ Description-Content-Type: text/markdown
|
|
|
41
41
|
[](https://iplotx.readthedocs.io/en/latest/)
|
|
42
42
|
[](https://coveralls.io/github/fabilab/iplotx?branch=main)
|
|
43
43
|

|
|
44
|
-
[
|
|
44
|
+
[DOI](https://f1000research.com/articles/14-1377)
|
|
45
45
|
|
|
46
46
|
|
|
47
47
|
# iplotx
|
|
@@ -90,10 +90,10 @@ See [readthedocs](https://iplotx.readthedocs.io/en/latest/) for the full documen
|
|
|
90
90
|
See [gallery](https://iplotx.readthedocs.io/en/latest/gallery/index.html).
|
|
91
91
|
|
|
92
92
|
## Citation
|
|
93
|
-
If you use `iplotx` for publication figures, please cite
|
|
93
|
+
If you use `iplotx` for publication figures, please cite:
|
|
94
94
|
|
|
95
95
|
```
|
|
96
|
-
F. Zanini.
|
|
96
|
+
F. Zanini. A universal tool for visualisation of networks and trees in Python. F1000Research 2025, 14:1377. https://doi.org/10.12688/f1000research.173131.1
|
|
97
97
|
```
|
|
98
98
|
|
|
99
99
|
## Features
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
[](https://iplotx.readthedocs.io/en/latest/)
|
|
4
4
|
[](https://coveralls.io/github/fabilab/iplotx?branch=main)
|
|
5
5
|

|
|
6
|
-
[
|
|
6
|
+
[DOI](https://f1000research.com/articles/14-1377)
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
# iplotx
|
|
@@ -52,10 +52,10 @@ See [readthedocs](https://iplotx.readthedocs.io/en/latest/) for the full documen
|
|
|
52
52
|
See [gallery](https://iplotx.readthedocs.io/en/latest/gallery/index.html).
|
|
53
53
|
|
|
54
54
|
## Citation
|
|
55
|
-
If you use `iplotx` for publication figures, please cite
|
|
55
|
+
If you use `iplotx` for publication figures, please cite:
|
|
56
56
|
|
|
57
57
|
```
|
|
58
|
-
F. Zanini.
|
|
58
|
+
F. Zanini. A universal tool for visualisation of networks and trees in Python. F1000Research 2025, 14:1377. https://doi.org/10.12688/f1000research.173131.1
|
|
59
59
|
```
|
|
60
60
|
|
|
61
61
|
## Features
|
|
@@ -112,6 +112,7 @@
|
|
|
112
112
|
# means a semicircle, and numbers above 5 create very large arcs, almost full
|
|
113
113
|
# circles. The exact definition of tension for arcs is the tangent of a
|
|
114
114
|
# quarter of the angle spanned by the arc.
|
|
115
|
+
# Tension is not used if explicit waypoints are set for the edge.
|
|
115
116
|
"tension": float,
|
|
116
117
|
|
|
117
118
|
# Tension for self-loops (higher values create more bigger loops).
|
|
@@ -151,8 +152,17 @@
|
|
|
151
152
|
# - ymidx0,ymidx1: The xy swap of the previous option.
|
|
152
153
|
# - x0y1: One waypoint, with x of the first point and y of the second point.
|
|
153
154
|
# - x1y0: The xy swap of the previous option.
|
|
154
|
-
#
|
|
155
|
-
|
|
155
|
+
#
|
|
156
|
+
# Instead of a string you can also specify a per-edge list of waypoints.
|
|
157
|
+
# Each waypoint is a tuple of two floats (x,y) in data coordinates. Each
|
|
158
|
+
# edge can have zero, one, or multiple waypoints.
|
|
159
|
+
# If used in this way, this option will have slightly different appearances
|
|
160
|
+
# depending of whether the edges are curved or straight (edge_curved). For
|
|
161
|
+
# straight edges, the edge will always pass through all waypoints. For
|
|
162
|
+
# curved edges, the waypoints are used as cubic Bezier control points and
|
|
163
|
+
# the edge will pass through the midpoints between each pair of consecutive
|
|
164
|
+
# waypoints.
|
|
165
|
+
"waypoints": str | list[list[tuple[float, float]]],
|
|
156
166
|
|
|
157
167
|
# Edge arrow style for directed graphs
|
|
158
168
|
"arrow": {
|
|
@@ -3,6 +3,12 @@
|
|
|
3
3
|
pip install iplotx
|
|
4
4
|
```
|
|
5
5
|
|
|
6
|
+
To also install [ilayoutx](https://ilayoutx.readthedocs.io/en/main/) to compute network layouts before visualising them:
|
|
7
|
+
|
|
8
|
+
```
|
|
9
|
+
pip install iplotx ilayoutx
|
|
10
|
+
```
|
|
11
|
+
|
|
6
12
|
|
|
7
13
|
## Quick Start
|
|
8
14
|
::::{tab-set}
|
|
@@ -71,10 +77,10 @@ Either way, the result is the same:
|
|
|
71
77
|
We believe graph **analysis**, graph **layouting**, and graph **visualisation** to be three separate tasks. `iplotx` currently focuses on visualisation. It can also compute simple tree layouts and might expand towards network layouts in the future.
|
|
72
78
|
|
|
73
79
|
## Citation
|
|
74
|
-
If you use `iplotx` for publication figures, please cite
|
|
80
|
+
If you use `iplotx` for publication figures, please cite:
|
|
75
81
|
|
|
76
82
|
```
|
|
77
|
-
F. Zanini.
|
|
83
|
+
F. Zanini. A universal tool for visualisation of networks and trees in Python. F1000Research 2025, 14:1377. https://doi.org/10.12688/f1000research.173131.1
|
|
78
84
|
```
|
|
79
85
|
|
|
80
86
|
## Contributing
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
Computation times
|
|
8
8
|
=================
|
|
9
|
-
**00:00.
|
|
9
|
+
**00:00.068** total execution time for 90 files **from all galleries**:
|
|
10
10
|
|
|
11
11
|
.. container::
|
|
12
12
|
|
|
@@ -32,8 +32,8 @@ Computation times
|
|
|
32
32
|
* - Example
|
|
33
33
|
- Time
|
|
34
34
|
- Mem (MB)
|
|
35
|
-
* - :ref:`
|
|
36
|
-
- 00:00.
|
|
35
|
+
* - :ref:`sphx_glr_gallery_fun_plot_67.py` (``../../gallery/fun/plot_67.py``)
|
|
36
|
+
- 00:00.068
|
|
37
37
|
- 0.0
|
|
38
38
|
* - :ref:`sphx_glr_gallery_basic_plot_3d.py` (``../../gallery/basic/plot_3d.py``)
|
|
39
39
|
- 00:00.000
|
|
@@ -92,6 +92,9 @@ Computation times
|
|
|
92
92
|
* - :ref:`sphx_glr_gallery_biology_plot_tca_cycle.py` (``../../gallery/biology/plot_tca_cycle.py``)
|
|
93
93
|
- 00:00.000
|
|
94
94
|
- 0.0
|
|
95
|
+
* - :ref:`sphx_glr_gallery_fun_plot_train.py` (``../../gallery/fun/plot_train.py``)
|
|
96
|
+
- 00:00.000
|
|
97
|
+
- 0.0
|
|
95
98
|
* - :ref:`sphx_glr_gallery_network_science_plot_arrowlawn.py` (``../../gallery/network_science/plot_arrowlawn.py``)
|
|
96
99
|
- 00:00.000
|
|
97
100
|
- 0.0
|
|
@@ -170,16 +173,19 @@ Computation times
|
|
|
170
173
|
* - :ref:`sphx_glr_gallery_other_plot_graph.py` (``../../gallery/other/plot_graph.py``)
|
|
171
174
|
- 00:00.000
|
|
172
175
|
- 0.0
|
|
176
|
+
* - :ref:`sphx_glr_gallery_other_plot_hover_neighborhood.py` (``../../gallery/other/plot_hover_neighborhood.py``)
|
|
177
|
+
- 00:00.000
|
|
178
|
+
- 0.0
|
|
173
179
|
* - :ref:`sphx_glr_gallery_other_plot_mouse_hover.py` (``../../gallery/other/plot_mouse_hover.py``)
|
|
174
180
|
- 00:00.000
|
|
175
181
|
- 0.0
|
|
176
182
|
* - :ref:`sphx_glr_gallery_other_plot_multiarc.py` (``../../gallery/other/plot_multiarc.py``)
|
|
177
183
|
- 00:00.000
|
|
178
184
|
- 0.0
|
|
179
|
-
* - :ref:`
|
|
185
|
+
* - :ref:`sphx_glr_gallery_style_plot_arrows.py` (``../../gallery/style/plot_arrows.py``)
|
|
180
186
|
- 00:00.000
|
|
181
187
|
- 0.0
|
|
182
|
-
* - :ref:`
|
|
188
|
+
* - :ref:`sphx_glr_gallery_style_plot_curved_waypoints.py` (``../../gallery/style/plot_curved_waypoints.py``)
|
|
183
189
|
- 00:00.000
|
|
184
190
|
- 0.0
|
|
185
191
|
* - :ref:`sphx_glr_gallery_style_plot_custom_vertex.py` (``../../gallery/style/plot_custom_vertex.py``)
|
|
@@ -191,6 +197,9 @@ Computation times
|
|
|
191
197
|
* - :ref:`sphx_glr_gallery_style_plot_edge_geometries.py` (``../../gallery/style/plot_edge_geometries.py``)
|
|
192
198
|
- 00:00.000
|
|
193
199
|
- 0.0
|
|
200
|
+
* - :ref:`sphx_glr_gallery_style_plot_edge_multicolor.py` (``../../gallery/style/plot_edge_multicolor.py``)
|
|
201
|
+
- 00:00.000
|
|
202
|
+
- 0.0
|
|
194
203
|
* - :ref:`sphx_glr_gallery_style_plot_edgepadding.py` (``../../gallery/style/plot_edgepadding.py``)
|
|
195
204
|
- 00:00.000
|
|
196
205
|
- 0.0
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
Gallery
|
|
2
|
+
=======
|
|
3
|
+
.. warning::
|
|
4
|
+
If plots do not show on screen, try adding `show=True` to your function call:
|
|
5
|
+
|
|
6
|
+
.. code-block::
|
|
7
|
+
|
|
8
|
+
ipx.network(
|
|
9
|
+
...,
|
|
10
|
+
show=True,
|
|
11
|
+
)
|
|
12
|
+
|
|
13
|
+
This is a peculiarity of `matplotlib`_, the plotting engine behind `iplotx`,
|
|
14
|
+
and depends on your Python environment (e.g., Jupyter notebooks, terminal,
|
|
15
|
+
interactive mode, backend, etc). You might want to enable `interactive mode`_
|
|
16
|
+
*before* plotting to ensure everything is rendered immediately:
|
|
17
|
+
|
|
18
|
+
.. code-block::
|
|
19
|
+
|
|
20
|
+
import matplotlib.pyplot as plt
|
|
21
|
+
import iplotx as ipx
|
|
22
|
+
|
|
23
|
+
...
|
|
24
|
+
|
|
25
|
+
plt.ion()
|
|
26
|
+
ipx.network(
|
|
27
|
+
...,
|
|
28
|
+
)
|
|
29
|
+
|
|
30
|
+
If interactive mode is on, you do not need `show=True` (because plots are
|
|
31
|
+
always rendered immediately anyway).
|
|
32
|
+
|
|
33
|
+
.. _matplotlib: https://matplotlib.org/
|
|
34
|
+
.. _interactive mode: https://matplotlib.org/stable/users/explain/figure/interactive.html
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"""
|
|
2
|
+
6-7
|
|
3
|
+
===
|
|
4
|
+
|
|
5
|
+
This example shows that yo 6-7.
|
|
6
|
+
"""
|
|
7
|
+
|
|
8
|
+
import igraph as ig
|
|
9
|
+
import matplotlib.pyplot as plt
|
|
10
|
+
import iplotx as ipx
|
|
11
|
+
|
|
12
|
+
g6 = ig.Graph.Ring(11, directed=True)
|
|
13
|
+
g0 = ig.Graph.Ring(4, directed=True)
|
|
14
|
+
gdash = ig.Graph(edges=[(0, 1), (1, 0)], directed=True)
|
|
15
|
+
g7 = ig.Graph.Ring(6, directed=True)
|
|
16
|
+
g67 = ig.disjoint_union([g6, g0, gdash, g7])
|
|
17
|
+
|
|
18
|
+
layout = [
|
|
19
|
+
# 6
|
|
20
|
+
[0, 0],
|
|
21
|
+
[1, 0],
|
|
22
|
+
[2, 1],
|
|
23
|
+
[2, 3],
|
|
24
|
+
[1, 4],
|
|
25
|
+
[0.8, 4],
|
|
26
|
+
[2, 6],
|
|
27
|
+
[1, 6],
|
|
28
|
+
[0, 4],
|
|
29
|
+
[-1, 2],
|
|
30
|
+
[-1, 1],
|
|
31
|
+
# 0
|
|
32
|
+
[0.3, 1.5],
|
|
33
|
+
[1.0, 1.5],
|
|
34
|
+
[1.0, 2.5],
|
|
35
|
+
[0.3, 2.5],
|
|
36
|
+
# dash
|
|
37
|
+
[3, 2],
|
|
38
|
+
[5, 2],
|
|
39
|
+
# 7
|
|
40
|
+
[6, 0],
|
|
41
|
+
[7, 0],
|
|
42
|
+
[8, 6],
|
|
43
|
+
[6, 6],
|
|
44
|
+
[6, 5],
|
|
45
|
+
[7, 5],
|
|
46
|
+
]
|
|
47
|
+
|
|
48
|
+
with ipx.style.context("unicorn"):
|
|
49
|
+
ipx.network(
|
|
50
|
+
g67,
|
|
51
|
+
layout,
|
|
52
|
+
node_size=9,
|
|
53
|
+
edge_linewidth=4,
|
|
54
|
+
)
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Hover neighborhoods
|
|
3
|
+
===================
|
|
4
|
+
|
|
5
|
+
This example shows how to highlight a node and its neighborhood by hovering with the mouse on it.
|
|
6
|
+
|
|
7
|
+
.. warning::
|
|
8
|
+
This example will run in a Python, IPython, or Jupyter session, however the
|
|
9
|
+
interactive functionality is not visible on the HTML page. Download the code
|
|
10
|
+
at the end of this page and run it in a local Python environment to see
|
|
11
|
+
the results.
|
|
12
|
+
"""
|
|
13
|
+
|
|
14
|
+
import matplotlib.pyplot as plt
|
|
15
|
+
import igraph as ig
|
|
16
|
+
import iplotx as ipx
|
|
17
|
+
|
|
18
|
+
g = ig.Graph.Erdos_Renyi(n=40, m=120)
|
|
19
|
+
layout = g.layout()
|
|
20
|
+
|
|
21
|
+
fig, axs = plt.subplots(1, 2, gridspec_kw={"width_ratios": [1, 0.2]}, figsize=(8, 6))
|
|
22
|
+
art = ipx.network(
|
|
23
|
+
g,
|
|
24
|
+
layout=layout,
|
|
25
|
+
ax=axs[0],
|
|
26
|
+
aspect=1,
|
|
27
|
+
vertex_zorder=5,
|
|
28
|
+
)[0]
|
|
29
|
+
base_nodecolors = art.get_vertices().get_facecolors()
|
|
30
|
+
nodecolors = base_nodecolors.copy()
|
|
31
|
+
edgecolors = art.get_edges().get_edgecolors()
|
|
32
|
+
edgewidths = art.get_edges().get_linewidths()
|
|
33
|
+
|
|
34
|
+
axs[1].set_axis_off()
|
|
35
|
+
txt = axs[1].text(0.5, 0.5, "", ha="center", va="center", wrap=True,
|
|
36
|
+
fontsize=40)
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
def hover_callback(event):
|
|
40
|
+
"""React to mouse hovering over vertices."""
|
|
41
|
+
if event.inaxes == axs[0]:
|
|
42
|
+
cont, ind = art.get_vertices().contains(event)
|
|
43
|
+
|
|
44
|
+
# Reset everyone's color
|
|
45
|
+
is_base = (nodecolors == base_nodecolors).all()
|
|
46
|
+
|
|
47
|
+
# If mouse is over a vertex, change the color around there
|
|
48
|
+
# and redraw
|
|
49
|
+
if cont:
|
|
50
|
+
i = ind["ind"][0]
|
|
51
|
+
nodecolors[:] = [0, 0, 0, 0.3]
|
|
52
|
+
nodecolors[g.neighbors(i)] = [1, 0, 0, 0.6]
|
|
53
|
+
nodecolors[i] = [1, 0, 0, 1]
|
|
54
|
+
art.get_vertices().set_facecolors(nodecolors)
|
|
55
|
+
edgecolors[:] = [0, 0, 0, 0.3]
|
|
56
|
+
edgecolors[g.incident(i)] = [0, 0, 0, 1]
|
|
57
|
+
art.get_edges().set_edgecolors(edgecolors)
|
|
58
|
+
edgewidths[:] = 1
|
|
59
|
+
edgewidths[g.incident(i)] = 2
|
|
60
|
+
art.get_edges().set_linewidths(edgewidths)
|
|
61
|
+
|
|
62
|
+
txt.set_text(str(i))
|
|
63
|
+
# Otherwise, change back to base and redraw
|
|
64
|
+
elif not is_base:
|
|
65
|
+
nodecolors[:] = base_nodecolors
|
|
66
|
+
vertex_artist.set_facecolors(nodecolors)
|
|
67
|
+
edgecolors[:] = [0, 0, 0, 1]
|
|
68
|
+
art.get_edges().set_edgecolors(edgecolors)
|
|
69
|
+
edgewidths[:] = 1
|
|
70
|
+
art.get_edges().set_linewidths(edgewidths)
|
|
71
|
+
txt.set_text("")
|
|
72
|
+
# If nothing changed, no need to redraw
|
|
73
|
+
else:
|
|
74
|
+
return
|
|
75
|
+
|
|
76
|
+
# Redraw if needed
|
|
77
|
+
fig.canvas.draw_idle()
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
fig.canvas.mpl_connect(
|
|
81
|
+
"motion_notify_event",
|
|
82
|
+
hover_callback,
|
|
83
|
+
)
|
|
@@ -43,7 +43,7 @@ def hover_callback(event):
|
|
|
43
43
|
if event.inaxes == ax:
|
|
44
44
|
vc = art.get_vertices()
|
|
45
45
|
cont, ind = vc.contains(event)
|
|
46
|
-
# If mouse is over a vertex, show the
|
|
46
|
+
# If mouse is over a vertex, show the bubble
|
|
47
47
|
if cont:
|
|
48
48
|
i = ind["ind"][0]
|
|
49
49
|
annot.xy = vc.get_offsets()[i]
|
|
@@ -6,10 +6,6 @@ This example demonstrates the use of curved edge waypoints.
|
|
|
6
6
|
For straight waypoints, the edge will pass through each waypoint.
|
|
7
7
|
For curved waypoints, they are used as cubic Bezier points to
|
|
8
8
|
interpolate smoothly between.
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
.. tip:
|
|
12
|
-
The edge will actually pass through the midpoints between two consecutive waypoints.
|
|
13
9
|
"""
|
|
14
10
|
|
|
15
11
|
import matplotlib.pyplot as plt
|
|
@@ -41,3 +37,7 @@ for ax, curved in zip(axs, [False, True]):
|
|
|
41
37
|
else:
|
|
42
38
|
ax.set_title("Curved waypoints")
|
|
43
39
|
fig.tight_layout()
|
|
40
|
+
|
|
41
|
+
#%%
|
|
42
|
+
# .. tip:: The edge will actually pass through the midpoints between two consecutive waypoints.
|
|
43
|
+
#
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"""
|
|
2
|
+
Multicolor edges
|
|
3
|
+
================
|
|
4
|
+
|
|
5
|
+
Sometimes the need arises to color edges with multiple colors at the same time. That's what multigraphs are for.
|
|
6
|
+
This example shows the concept in action.
|
|
7
|
+
|
|
8
|
+
"""
|
|
9
|
+
|
|
10
|
+
import networkx as nx
|
|
11
|
+
import matplotlib.pyplot as plt
|
|
12
|
+
import iplotx as ipx
|
|
13
|
+
|
|
14
|
+
g = nx.MultiGraph()
|
|
15
|
+
g.add_edges_from([(0, 1), (1, 2), (0, 2), (0, 1)])
|
|
16
|
+
|
|
17
|
+
layout = [(0, 0), (1, 0), (0.5, 1)]
|
|
18
|
+
|
|
19
|
+
ipx.network(
|
|
20
|
+
g,
|
|
21
|
+
layout,
|
|
22
|
+
edge_color=["black", "gold", "tomato", "tomato"],
|
|
23
|
+
edge_paralleloffset=8,
|
|
24
|
+
edge_linewidth=4,
|
|
25
|
+
vertex_size=40,
|
|
26
|
+
vertex_facecolor="none",
|
|
27
|
+
vertex_edgecolor="black",
|
|
28
|
+
vertex_linewidth=4,
|
|
29
|
+
)
|
|
@@ -20,6 +20,7 @@ from .network import NetworkArtist
|
|
|
20
20
|
from .network.groups import GroupingCollection
|
|
21
21
|
from .tree import TreeArtist
|
|
22
22
|
from .style import context
|
|
23
|
+
from .utils.matplotlib import _heuristic_show
|
|
23
24
|
|
|
24
25
|
|
|
25
26
|
def network(
|
|
@@ -36,6 +37,7 @@ def network(
|
|
|
36
37
|
margins: float | tuple[float, float] | tuple[float, float, float] = 0,
|
|
37
38
|
strip_axes: bool = True,
|
|
38
39
|
figsize: Optional[tuple[float, float]] = None,
|
|
40
|
+
show: Optional[bool] = None,
|
|
39
41
|
**kwargs,
|
|
40
42
|
) -> list[mpl.artist.Artist]:
|
|
41
43
|
"""Plot this network and/or vertex grouping using the specified layout.
|
|
@@ -70,6 +72,9 @@ def network(
|
|
|
70
72
|
figsize: If ax is None, a new matplotlib Figure is created. This argument specifies
|
|
71
73
|
the (width, height) dimension of the figure in inches. If ax is not None, this
|
|
72
74
|
argument is ignored. If None, the default matplotlib figure size is used.
|
|
75
|
+
show: If True, call plt.show() after plotting. If False, do not call plt.show(). If
|
|
76
|
+
None (default), try to guess based on the environment and do not show in case of
|
|
77
|
+
doubt.
|
|
73
78
|
kwargs: Additional arguments are treated as an alternate way to specify style. If
|
|
74
79
|
both "style" and additional **kwargs are provided, they are both applied in that
|
|
75
80
|
order (style, then **kwargs).
|
|
@@ -78,7 +83,12 @@ def network(
|
|
|
78
83
|
A list of mpl.artist.Artist objects, set as a direct child of the matplotlib Axes.
|
|
79
84
|
The list can have one or two elements, depending on whether you are requesting to
|
|
80
85
|
plot a network, a grouping, or both.
|
|
86
|
+
|
|
87
|
+
NOTE: If your plots are now showing to screen, try passing show=True.
|
|
81
88
|
"""
|
|
89
|
+
if show is None:
|
|
90
|
+
show = _heuristic_show()
|
|
91
|
+
|
|
82
92
|
# Equivalence of node_labels and vertex_labels
|
|
83
93
|
if node_labels is not None:
|
|
84
94
|
vertex_labels = node_labels
|
|
@@ -164,6 +174,9 @@ def network(
|
|
|
164
174
|
if (margins[0] != 0) or (margins[1] != 0) or ((len(margins) == 3) and (margins[2] != 0)):
|
|
165
175
|
ax.margins(*margins)
|
|
166
176
|
|
|
177
|
+
if show:
|
|
178
|
+
plt.show()
|
|
179
|
+
|
|
167
180
|
return artists
|
|
168
181
|
|
|
169
182
|
|
|
@@ -187,6 +200,7 @@ def tree(
|
|
|
187
200
|
margins: float | tuple[float, float] = 0,
|
|
188
201
|
strip_axes: bool = True,
|
|
189
202
|
figsize: Optional[tuple[float, float]] = None,
|
|
203
|
+
show: Optional[bool] = None,
|
|
190
204
|
**kwargs,
|
|
191
205
|
) -> TreeArtist:
|
|
192
206
|
"""Plot a tree using the specified layout.
|
|
@@ -226,13 +240,21 @@ def tree(
|
|
|
226
240
|
figsize: If ax is None, a new matplotlib Figure is created. This argument specifies
|
|
227
241
|
the (width, height) dimension of the figure in inches. If ax is not None, this
|
|
228
242
|
argument is ignored. If None, the default matplotlib figure size is used.
|
|
243
|
+
show: If True, call plt.show() after plotting. If False, do not call plt.show(). If
|
|
244
|
+
None (default), try to guess based on the environment and do not show in case of
|
|
245
|
+
doubt.
|
|
229
246
|
kwargs: Additional arguments are treated as an alternate way to specify style. If
|
|
230
247
|
both "style" and additional **kwargs are provided, they are both applied in that
|
|
231
248
|
order (style, then **kwargs).
|
|
232
249
|
|
|
233
250
|
Returns:
|
|
234
251
|
A TreeArtist object, set as a direct child of the matplotlib Axes.
|
|
252
|
+
|
|
253
|
+
NOTE: If your plots are now showing to screen, try passing show=True.
|
|
235
254
|
"""
|
|
255
|
+
if show is None:
|
|
256
|
+
show = _heuristic_show()
|
|
257
|
+
|
|
236
258
|
# Equivalence of node_labels and vertex_labels
|
|
237
259
|
if node_labels is not None:
|
|
238
260
|
vertex_labels = node_labels
|
|
@@ -270,6 +292,9 @@ def tree(
|
|
|
270
292
|
if (margins[0] != 0) or (margins[1] != 0):
|
|
271
293
|
ax.margins(*margins)
|
|
272
294
|
|
|
295
|
+
if show:
|
|
296
|
+
plt.show()
|
|
297
|
+
|
|
273
298
|
return artist
|
|
274
299
|
|
|
275
300
|
|
|
@@ -285,6 +310,7 @@ def doubletree(
|
|
|
285
310
|
margins: float | tuple[float, float] = 0,
|
|
286
311
|
strip_axes: bool = True,
|
|
287
312
|
figsize: Optional[tuple[float, float]] = None,
|
|
313
|
+
show: Optional[bool] = None,
|
|
288
314
|
) -> tuple[TreeArtist, TreeArtist]:
|
|
289
315
|
"""Visualize two trees facing each other.
|
|
290
316
|
|
|
@@ -306,9 +332,26 @@ def doubletree(
|
|
|
306
332
|
figsize: If ax is None, a new matplotlib Figure is created. This argument specifies
|
|
307
333
|
the (width, height) dimension of the figure in inches. If ax is not None, this
|
|
308
334
|
argument is ignored. If None, the default matplotlib figure size is used.
|
|
335
|
+
show: If True, call plt.show() after plotting. If False, do not call plt.show(). If
|
|
336
|
+
None (default), try to guess based on the environment and do not show in case of
|
|
337
|
+
doubt.
|
|
309
338
|
Returns:
|
|
310
339
|
A tuple with the left and right TreeArtist objects.
|
|
340
|
+
|
|
341
|
+
NOTE: If your plots are now showing to screen, try passing show=True.
|
|
311
342
|
"""
|
|
343
|
+
if show is None:
|
|
344
|
+
show = _heuristic_show()
|
|
345
|
+
|
|
346
|
+
if kwargs_left is None:
|
|
347
|
+
kwargs_left = {}
|
|
348
|
+
if "show" not in kwargs_left:
|
|
349
|
+
kwargs_left["show"] = False
|
|
350
|
+
if kwargs_right is None:
|
|
351
|
+
kwargs_right = {}
|
|
352
|
+
if "show" not in kwargs_right:
|
|
353
|
+
kwargs_right["show"] = False
|
|
354
|
+
|
|
312
355
|
artist1 = tree(
|
|
313
356
|
tree_left,
|
|
314
357
|
layout="horizontal",
|
|
@@ -316,14 +359,11 @@ def doubletree(
|
|
|
316
359
|
ax=ax,
|
|
317
360
|
strip_axes=False,
|
|
318
361
|
figsize=figsize,
|
|
319
|
-
**kwargs_left
|
|
362
|
+
**kwargs_left,
|
|
320
363
|
)
|
|
321
364
|
|
|
322
365
|
ax = artist1.axes
|
|
323
366
|
|
|
324
|
-
if kwargs_right is None:
|
|
325
|
-
kwargs_right = {}
|
|
326
|
-
|
|
327
367
|
had_layout_start = "layout_start" in kwargs_right
|
|
328
368
|
|
|
329
369
|
artist2 = tree(
|
|
@@ -348,6 +388,9 @@ def doubletree(
|
|
|
348
388
|
|
|
349
389
|
_postprocess_axes(ax, [artist1, artist2], strip=strip_axes, ignore_previous=True)
|
|
350
390
|
|
|
391
|
+
if show:
|
|
392
|
+
plt.show()
|
|
393
|
+
|
|
351
394
|
return (artist1, artist2)
|
|
352
395
|
|
|
353
396
|
|
|
@@ -282,3 +282,8 @@ def _get_data_scale(X, Y, Z):
|
|
|
282
282
|
ptp_y = Y.max() - Y.min()
|
|
283
283
|
ptp_z = Z.max() - Z.min()
|
|
284
284
|
return np.sqrt(ptp_x**2 + ptp_y**2 + ptp_z**2)
|
|
285
|
+
|
|
286
|
+
|
|
287
|
+
def _heuristic_show():
|
|
288
|
+
"""Try guessing whether plt.show() should be called automatically."""
|
|
289
|
+
return False
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "iplotx"
|
|
7
|
-
description = "
|
|
7
|
+
description = "Universal network and tree visualisation library."
|
|
8
8
|
authors = [
|
|
9
9
|
{name = "Fabio Zanini", email = "fabio.zanini@unsw.edu.au"}
|
|
10
10
|
]
|
|
Binary file
|