I need help with setting the limits of y-axis on matplotlib. Here is the code that I tried, unsuccessfully.
import matplotlib.pyplot as plt plt.figure(1, fi
You can instantiate an object from matplotlib.pyplot.axes and call the set_ylim() on it. It would be something like this:
matplotlib.pyplot.axes
set_ylim()
import matplotlib.pyplot as plt axes = plt.axes() axes.set_ylim([0, 1])