Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Document] Add (or update) an example to demonstrate converting node/edge attributes in from_networkx #8286

Closed
komo-fr opened this issue Sep 29, 2018 · 3 comments · Fixed by #8291

Comments

@komo-fr
Copy link
Contributor

komo-fr commented Sep 29, 2018

Add (or update) an example to demonstrate converting node/edge attributes in from_networkx.

Related an issue/PR:

I think that it is easier to understand that node / edge attributes are being converted in from_networkx by adding an example that displays node hover information at the end of this page.
Visualizing Network Graphs
https://bokeh.pydata.org/en/latest/docs/user_guide/graph.html

Draft

The example draft to be added is as follows.
http://nbviewer.jupyter.org/github/komo-fr/networkx2bokeh_note/blob/master/notebooks/graph_example_hovering_node_attributes.ipynb

If there is not particularly big problem with this content, I will send a PR.

@bryevdv
Copy link
Member

bryevdv commented Sep 30, 2018

@komo-fr That looks like a nice example, would be glad to accept a PR to add it.

@codercahol
Copy link

It would also be very helpful if the procedure for accessing edge attributes / labelling them was more clearly documented

@komo-fr
Copy link
Contributor Author

komo-fr commented Oct 1, 2018

@bryevdv
Thank you for the reply.
I added an example that uses edge attributes for a comment from @codercahol.

Draft 2
http://nbviewer.jupyter.org/github/komo-fr/networkx2bokeh_note/blob/master/notebooks/graph_example_using_node_and_edge_attributes.ipynb?flush_cache=true

In order to display the node / edge attributes in node_renderer / edge_renderer as a label, it seems that GraphRenderer itself needs additional modification.
Therefore, it is not shown in the example above.
Instead, I added codes to change the edge color using edge attributes.

I sent a PR with this content, so I would like to discuss it there.

bryevdv pushed a commit that referenced this issue Oct 2, 2018
…8291)

* Add an example to demonstrate converting node/edge attributes in from_networkx (#8286)

* Fixed the title underline is too short

* remove print() to be consistent
@bryevdv bryevdv added this to the 1.0 milestone Oct 2, 2018
xavArtley pushed a commit to xavArtley/bokeh that referenced this issue Oct 15, 2018
…okeh#8291)

* Add an example to demonstrate converting node/edge attributes in from_networkx (bokeh#8286)

* Fixed the title underline is too short

* remove print() to be consistent
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants