【问题标题】:What does this => x = np.arange(len(labels)) mean when plotting a grouped bar chart using MatPlotLib?使用 MatPlotLib 绘制分组条形图时,这个 => x = np.arange(len(labels)) 是什么意思?
【发布时间】:2022-11-17 01:43:22
【问题描述】:

比如,它是做什么的?我在模板中看到了它。

【问题讨论】:

标签: python matplotlib bar-chart grouped-bar-chart


【解决方案1】:

它为 x 值分配一个数字为 0 到 len(labels)-1 的数组

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2020-01-22
    • 2019-04-24
    • 2020-02-07
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-03-22
    相关资源
    最近更新 更多