I have a pandas DataFrame that looks something like this:
n=pd.DataFrame({1:[1,2,np.NAN,4],2:[5,6,5,8],'info':[5,6,8,7],'moreinfo':[1,2,5,8]}).set_index(['info','moreinfo'])
Which looks like this:
1 2
info moreinfo
5 1 1.0 5
6 2 2.0 6
8 5 NaN 5
7 8 4.0 8
How can I line plot this such that:
The column labels are used as the xlabels
The data is grouped and colored by index
The y-axis is the numerical data found within each column.
Below is an example of what I'm thinking the plot should look like:



NaNbe treated?