# bokeh-graph
Interactive Graph visualization for networkX Graphs
# Basic Usage
```python
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
```python
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.
```
Raw data
{
"_id": null,
"home_page": "https://github.com/luerhard/bokehgraph",
"name": "bokehgraph",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.8,<4.0",
"maintainer_email": "",
"keywords": "",
"author": "Lukas Erhard",
"author_email": "luerhard@googlemail.com",
"download_url": "https://files.pythonhosted.org/packages/ef/b6/95b5a3e5900fb263f03b452f36d3b751fb0680287958296160a006fbd559/bokehgraph-0.3.2.tar.gz",
"platform": null,
"description": "# bokeh-graph\nInteractive Graph visualization for networkX Graphs\n\n# Basic Usage\n```python\nfrom bokehgraph import BokehGraph\nimport networkx as nx\n\ngraph = nx.karate_club_graph()\n\nplot = BokehGraph(graph)\nplot.draw()\n```\n\n## Jupyter Notebooks\nTo show graphs inlined in Jupyter Notebooks set the `inline` parameter\n```python\nplot = BokehGraph(graph, width=300, height=300, inline=True)\n```\n\n## Draw parameters\n\nThe `BokehGraph.draw()` method has a couple of parameters to individualize the resulting plot:\n```\nnode_color=\"firebrick\"\nSet node color to any valid bokeh color (only respected if color_by is not set)\n\npalette=None\nSet palette to any valid bokeh color palette.\nA list of palettes can be found under: https://docs.bokeh.org/en/latest/docs/reference/palettes.html\n\ncolor_by=None\nSet to a node attribute to color nodes by this attribute\n\nedge_color=\"navy\"\nSet node color to any valid bokeh color\n\nedge_alpha=0.17\nSet edge alpha to a value between [0,1]\n\nnode_alpha=0.7\nSet edge alpha to a value between [0,1]\n\nnode_size=9\nSet node size\n\nmax_colors=-1\nSet a maximum number of colors for color_by (or -1 to use as many colors as possible).\nThis must be < 256 and lower than the maximum number of colors of your selected palette.\nIt will divide the attribute space into evenly spaced to colors.\n```",
"bugtrack_url": null,
"license": "MIT",
"summary": "Interactive Graph visualization for networkX Graphs",
"version": "0.3.2",
"project_urls": {
"Homepage": "https://github.com/luerhard/bokehgraph"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "23bf5a96d7e1320850757643d210932ee73d5b80a43d779f584c63549d8c49c2",
"md5": "f7a8d97c1b37c6fade3d0f863aa24bd9",
"sha256": "ae0474188301c4cfa95b43a7f3921ab2df0750d5f62dd75333531179e1bcd384"
},
"downloads": -1,
"filename": "bokehgraph-0.3.2-py3-none-any.whl",
"has_sig": false,
"md5_digest": "f7a8d97c1b37c6fade3d0f863aa24bd9",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8,<4.0",
"size": 6613,
"upload_time": "2024-03-13T18:52:47",
"upload_time_iso_8601": "2024-03-13T18:52:47.045391Z",
"url": "https://files.pythonhosted.org/packages/23/bf/5a96d7e1320850757643d210932ee73d5b80a43d779f584c63549d8c49c2/bokehgraph-0.3.2-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "efb695b5a3e5900fb263f03b452f36d3b751fb0680287958296160a006fbd559",
"md5": "f5cb79015344bd823a7a480f4c8e789e",
"sha256": "91d642a5379c583b56511f4759e0a63172da0a7028e81233e9194e524d5acadd"
},
"downloads": -1,
"filename": "bokehgraph-0.3.2.tar.gz",
"has_sig": false,
"md5_digest": "f5cb79015344bd823a7a480f4c8e789e",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8,<4.0",
"size": 5709,
"upload_time": "2024-03-13T18:52:48",
"upload_time_iso_8601": "2024-03-13T18:52:48.590760Z",
"url": "https://files.pythonhosted.org/packages/ef/b6/95b5a3e5900fb263f03b452f36d3b751fb0680287958296160a006fbd559/bokehgraph-0.3.2.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-03-13 18:52:48",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "luerhard",
"github_project": "bokehgraph",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"tox": true,
"lcname": "bokehgraph"
}