I have the following pandas dataframe
import pandas as pd
df = pd.DataFrame(zip(["A","B", "C", "D"],[10,30,55,60]), columns=["Name", "Distance"])
Out:
Name Distance
0 A 10
1 B 30
2 C 55
3 D 60
Now, I would like to make a distance matrix, i.e.
Does anyone know how to make this efficiently with python?