Skip to content

Node names missing in dataframe from get_networkx_graph_as_dataframe_of_edges #113

@agitter

Description

@agitter

Calling get_networkx_graph_as_dataframe_of_edges on the augmented forest generated a data frame that has node names only for the edges that are in the optimal forest solution. For instance:

protein1	protein2	cost	in_solution
A	C	0.1	True
C	D	0.1	True
		10.0	

The last row is for the edge A-D.

This happens because the forest graph has protein1 and protein2 as edge attributes. These are also the keys used when exporting the graph to a dataframe, and the edge attributes overwrite the initial key-value pairs for each edge.

I believe I have a fix that I will push to my fork. I can submit a pull request here if you would like.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions