línea horizontal matplotlib python
import matplotlib.pyplot as plt
plt.axhline(0)
Tremendous Enceladus
import matplotlib.pyplot as plt
plt.axhline(0)
import matplotlib.pyplot as plt
import numpy as np
x = np.linspace(1, 21, 200)
y = np.exp(-x)
fig, ax = plt.subplots()
ax.plot(x, y)
ax.hlines(y=0.2, xmin=4, xmax=20, linewidth=2, color='r')
plt.show()
This will plot y=0 horizontal line ,
import matplotlib.pyplot as plt
plt.axhline(0)
import matplotlib.pyplot as plt
series.plot(kind='barh')
plt.show()
[ax.axhiline(y=i, linestyle='--') for i in [150,100,200,300]]