I have the following as my code with the following graph displaying
Problem is, I wanted to compare each attribute(mean age, age amount etc) next to each other. By default, pandas takes x as the index. How do I change it to take column names instead(Then there will be 3 comparisons, one for each attribute)
CodePudding user response:
IIUC use transpose with DataFrame.plot.bar
:
df.T.plot.bar()