• 首页 首页 icon
  • 工具库 工具库 icon
    • IP查询 IP查询 icon
  • 内容库 内容库 icon
    • 快讯库 快讯库 icon
    • 精品库 精品库 icon
    • 问答库 问答库 icon
  • 更多 更多 icon
    • 服务条款 服务条款 icon

pandas 图()没有图例

用户头像
it1352
帮助1

问题说明

在python中使用pandas库并使用

Using the pandas library in python and using

.plot()

在数据框上,如何显示没有图例的图?

on a dataframe, how do I display the plot without a legend?

正确答案

#1

函数中有一个对应于图例的参数;默认情况下为True

There is a parameter in the function corresponding to legend; by default it is True

df.plot(legend=False)

以下是.plot()方法的定义

定义:df.plot(frame = None,x = None,y = None,subplots = False,sharex = True,sharey = False,use_index = True,figsize = None,grid = None,legend = True,rot = None,ax = None,style = None,title = None,xlim = None,ylim = None,logx = False,logy = False,xticks = None,yticks = None,kind ='line',sort_columns = False,fontsize = None,secondary_y = False,** kwds)

Definition: df.plot(frame=None, x=None, y=None, subplots=False, sharex=True, sharey=False, use_index=True, figsize=None, grid=None, legend=True, rot=None, ax=None, style=None, title=None, xlim=None, ylim=None, logx=False, logy=False, xticks=None, yticks=None, kind='line', sort_columns=False, fontsize=None, secondary_y=False, **kwds)

这篇好文章是转载于:学新通技术网

  • 版权申明: 本站部分内容来自互联网,仅供学习及演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,请提供相关证据及您的身份证明,我们将在收到邮件后48小时内删除。
  • 本站站名: 学新通技术网
  • 本文地址: /reply/detail/tanhcgkajb
系列文章
更多 icon
同类精品
更多 icon
继续加载