I've got a huge DataFrame. This just an example. But you can see that "b" element has "a", "d", "k" parents.
data = pd.DataFrame(columns=["Parent","Child"], data=[["a","b"],["a","d"],["d","v"],["d","b"],["c","f"],["b","n"],["s","c"],["k","b"],["n","k"]])
Read data from a pandas DataFrame and create a tree using anytree in python
In this solution tree is building, but parents overwriting.
How to build multiple parents tree? P.S Maybe my array is bad.