|
Matplotlib da Figure moduli
|
bet | 4/4 | Sana | 17.01.2024 | Hajmi | 8,58 Kb. | | #139190 |
Bog'liq Elektron ta’lim resurslarini yaratish texnologiyalari-kompy.info
Ma’ruzachi: Rustamov H.Sh, E-mail: rhsh0405@gmail.com, Telefon: 91-979-04-75
matplotlib.pyplot.figure() funksiyasi matplotlib kutubxonasi moduli bo’lib yangi figuralar hosil qilish uchun foydalaniladi
Sintaksisi
matplotlib.pyplot.figure(num=None, figsize=None, dpi=None, facecolor=None, edgecolor=None, frameon=True, FigureClass=, clear=False, **kwargs)
Parametrlari
Ma’ruzachi: Rustamov H.Sh, E-mail: rhsh0405@gmail.com, Telefon: 91-979-04-75
frameon : Bu parametr rasm ramkasini chizishni amalga oshiradi. FigureClass : Ushbu parametr maxsus shakl namunasidan foydalanadi. clear : Agar bu parametr True bo’lsa chizma yoki qaralayotgan shakl allaqachon mavjud bo’lib, u o'chiriladi. Return value: Bu usul quyidagi qiymatlarni qaytaradi: figure : Bu parametr Figure moduli namunasini qaytaradi, shuningdek uni backend dagi new_figure_manager ga uzatiladi.
Ma’ruzachi: Rustamov H.Sh, E-mail: rhsh0405@gmail.com, Telefon: 91-979-04-75
NAMUNA: import matplotlib.pyplot as plt import matplotlib.lines as lines fig = plt.figure() fig.add_artist(lines.Line2D([0, 1, 0.5], [0, 1, 0.3])) fig.add_artist(lines.Line2D([0, 1, 0.5], [1, 0, 0.2])) plt.title('matplotlib.pyplot.figure() Example\n', fontsize = 14, fontweight ='bold') plt.show()
http://kompy.info
|
| |