ax=plt.axes ax.spines['top'].set_visible(False) ax.spines['right'].set_visible(False)
时间: 2024-05-29 12:09:50 浏览: 122
matplotilb中fig,ax = plt.subplots()的使用
These lines of code create an axes object using the `plt.axes` method and then hide the top and right spines (axis lines) of the plot by setting their visibility to False using the `ax.spines` method. This results in a plot with only the left and bottom spines visible.
阅读全文