Creating a Sankey Plot

I have the following data set in python dataframe:

A   2|3|1|3
B    1|2|3|1

A and B are in the index column.How do I create a sankey plot for this data to show transition from one semester to another semester

Hi @Sam2, did you take a look at the examples in Basically you need to extract the values from your dataframe for the node and link parameter of the trace.

Yes I visited it,but I am not sure how to extract it from the dataframe which I have

I have passed and plotted the Sankey diagram using the python library.
But every time when I run, it is generated in local IP with a new port no like
Since I am using real values to plot the Sankey, I want the plot to be used in python so I want my graph to get updated as per the value, so I can use active to show the same graph in python