Skip to main content

bokeh-graph

Interactive Graph visualization for networkX Graphs

Basic Usage

from bokehgraph import BokehGraph
import networkx as nx

graph = nx.karate_club_graph()

plot = BokehGraph(graph)
plot.draw()

Jupyter Notebooks

To show graphs inlined in Jupyter Notebooks set the inline parameter

plot = BokehGraph(graph, width=300, height=300, inline=True)

Draw parameters

The BokehGraph.draw() method has a couple of parameters to individualize the resulting plot:

node_color="firebrick"
Set node color to any valid bokeh color (only respected if color_by is not set)

palette=None
Set palette to any valid bokeh color palette.
A list of palettes can be found under: https://docs.bokeh.org/en/latest/docs/reference/palettes.html

color_by=None
Set to a node attribute to color nodes by this attribute

edge_color="navy"
Set node color to any valid bokeh color

edge_alpha=0.17
Set edge alpha to a value between [0,1]

node_alpha=0.7
Set edge alpha to a value between [0,1]

node_size=9
Set node size

max_colors=-1
Set a maximum number of colors for color_by (or -1 to use as many colors as possible).
This must be < 256 and lower than the maximum number of colors of your selected palette.
It will divide the attribute space into evenly spaced to colors.

Metadata

Release files for bokehgraph 0.3.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bokehgraph 0.3.1
File Size Uploaded
bokehgraph-0.3.1.tar.gz 5.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for bokehgraph 0.3.1
File Interpreter ABI Platform
bokehgraph-0.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 12.2 kB

Release files / bokehgraph-0.3.1.tar.gz

Download URL bokehgraph-0.3.1.tar.gz
Size 5.7 kB
Tags Source
SHA-256 checksum
How to use checksums
43601a53e65f596cfc4f8ff4dfefc9ef40efd653fcbf04c8b88244c701dae01d
BLAKE2b-256 checksum
How to use checksums
2ba5bd1e9a1884ca20a5fc3a0fa059061b53bffead09008be4d809b4388616e9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.1 CPython/3.11.6 Linux/6.2.0-1016-azure

Release files / bokehgraph-0.3.1-py3-none-any.whl

Download URL bokehgraph-0.3.1-py3-none-any.whl
Size 6.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e9a4e06a77ffbc5a2a7b97ff2cfb1fd3e55519197b6ce5e87dc55ef85cb5f6b8
BLAKE2b-256 checksum
How to use checksums
f188a44c07e11e4dadbbc8f4bdb523cc1b6566dcf02e59f10be67404305342d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.7.1 CPython/3.11.6 Linux/6.2.0-1016-azure

Release history Release notifications | RSS feed

1.1.0

2 release files

1.0.0

2 release files

0.6.4

2 release files

0.6.3

2 release files

0.6.2

2 release files

0.6.1

2 release files

0.6.0

2 release files

0.5.0

2 release files

0.4.6

2 release files

0.4.5

2 release files

0.4.4

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.2

2 release files

This release

0.3.1 This release

2 release files

0.3.0

2 release files

0.2.0

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page