What do you want to save?
Add Code snippet
New code examples
-
Python 2021-10-18 02:11:03
python matplotlib how to graph point on line
import matplotlib.pyplot as plt fig = plt.figure() ax = fig.add_subplot(111) ax.set_xlim(0,10) ax.set_ylim(0,10) # draw lines xmin = 1 xmax = 9 y = 5 height = 1 plt.hlines(y, xmin, xmax) plt.vlines(xmin, y - height / 2., y + height / 2.) plt.vlines(xmax,... Add solution