Update code to use networkx objects (incomplete)#1
Open
willu47 wants to merge 5 commits intoscripts_developmentfrom
Open
Update code to use networkx objects (incomplete)#1willu47 wants to merge 5 commits intoscripts_developmentfrom
willu47 wants to merge 5 commits intoscripts_developmentfrom
Conversation
willu47
commented
Oct 9, 2020
| # Write out the graph to a new file | ||
| nx.write_graphml(RES, 'glucoseRES_modified,noDUMMY,v4_202010.graphml') | ||
|
|
||
| # %% |
Author
There was a problem hiding this comment.
This line here allows you to run the file from the command line and pass in a variable e.g.
python GLUCOSE_VisualizingRES.py glucoseRES_modified,noDUMMY,v2_202010.graphmlI'd recommend using shorter file names (because it's easier to type shorter names).
…Frame with networkx data structure
willu47
commented
Oct 12, 2020
willu47
commented
Oct 12, 2020
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi @AgnesBelt - I've had a look at your code and simplified it. I removed use of the pandas DataFrames as it was making the code very complicated. Everything you need is provided by networkx, but understanding the data structure of the networkx Graph isn't that easy.
I believe It is now working, and adds labels from the list of input_edges to the relevant nodes. I've left the output and emission edges an exercise for you to complete!
I'll add some comments below in the text, and you can ask questions below too.
I suggest you pull down this branch and then push your commits to the same branch. Then we can track progress and I can help if needed here too.