I have a dataframe like so:
ID | Node 1 | Node 2 | Node 3
a | 1 | 0 | 1
b | 0 | 1 | 1
c | 1 | 0 | 0
d | 1 | 1 | 1
e | 0 | 1 | 1
I want to change it so that I can turn it into a network chart, where connections between nodes are the amount of times an ID is indicated for both of them:
Node A | Node B | Weight |
Node 1 | Node 2 | 1 |
Node 1 | Node 3 | 2 |
Node 2 | Node 3 | 3 |