Matplotlib是Python中的一个库,它是数字的-NumPy库的数学扩展。 Pyplot是Matplotlib模块的基于状态的接口,该模块提供了MATLAB-like接口。可在Pyplot中使用的各种图线图,轮廓图,直方图,散点图,3D图等。
matplotlib.pyplot.get_plot_commands()方法
matplotlib库的pyplot模块中的get_plot_commands()方法用于获取所有绘图命令的排序列表。
用法:matplotlib.pyplot.get_plot_commands()
参数:此方法不接受任何参数。
返回:此方法返回所有绘图命令的排序列表。
以下示例说明了matplotlib.pyplot中的matplotlib.pyplot.get_plot_commands()函数:
例:
# Implementation of matplotlib function
import numpy as np
import matplotlib.pyplot as plt
w = plt.get_plot_commands()
print("List of all of the plotting commands:")
for i in w:
print(i)
输出:
List of all of the plotting commands: acorr angle_spectrum annotate arrow autoscale axes axhline axhspan axis axvline axvspan bar barbs barh box boxplot broken_barh cla clabel clf clim close cohere colorbar contour contourf csd delaxes draw errorbar eventplot figimage figlegend fignum_exists figtext figure fill fill_between fill_betweenx findobj gca gcf gci get_figlabels get_fignums grid hexbin hist hist2d hlines imread imsave imshow install_repl_displayhook ioff ion isinteractive legend locator_params loglog magnitude_spectrum margins matshow minorticks_off minorticks_on pause pcolor pcolormesh phase_spectrum pie plot plot_date plotfile polar psd quiver quiverkey rc rc_context rcdefaults rgrids savefig sca scatter sci semilogx semilogy set_cmap setp show specgram spy stackplot stem step streamplot subplot subplot2grid subplot_tool subplots subplots_adjust suptitle switch_backend table text thetagrids tick_params ticklabel_format tight_layout title tricontour tricontourf tripcolor triplot twinx twiny uninstall_repl_displayhook violinplot vlines xcorr xkcd xlabel xlim xscale xticks ylabel ylim yscale yticks
注:本文由纯净天空筛选整理自SHUBHAMSINGH10大神的英文原创作品 Matplotlib.pyplot.get_plot_commands() in Python。非经特殊声明,原始代码版权归原作者所有,本译文未经允许或授权,请勿转载或复制。