Pandas offers a nice, simple way to plot a (vertical) bar chart on two y axes. Is there an equivalent for the horizontal bar chart?
To adapt from the linked example:
import matplotlib.pyplot as plt
import numpy as np
import pandas as pd
from io import StringIO
s = StringIO(""" amount price
A 40929 4066443
B 93904 9611272
C 188349 19360005
D 248438 24335536
E 205622 18888604
F 140173 12580900
G 76243 6751731
H 36859 3418329
I 29304 2758928
J 39768 3201269
K 30350 2867059""")
df = pd.read_csv(s, index_col=0, delimiter=' ', skipinitialspace=True)
_ = df.plot( kind= 'barh' , secondary_y= 'amount' , rot= 0 )
# Doesn't work as expected. And there's no secondary_x.
plt.show()