This commit is contained in:
pluv committed 2026-10-09 14:11:54 +08:00
1 parent ae0d509dbd
commit 029237b364
12 files changed
+1055 -116

No files matched your search

+22
View File
@@ -0,0 +1,22 @@
#**********begin**********#
#绘制直角坐标系
#(1)导入matplotlib.pyplot库,重命名为plt
import matplotlib.pyplot as plt
def level1():
#(2)创建10*10的绘图区域
plt.figure(figsize=(10, 10))
#(3)设置坐标系x,y轴的取值范围为0-100
plt.xlim(0, 100)
plt.ylim(0, 100)
#(4)开启坐标网格
plt.grid(True)
#(5)显示创建的绘图对象
plt.show()
#**********end**********#
#将绘制的图形保存为指定路径下的图片
plt.savefig("task1/image1/t1.png")