Skip to content

Pass 'width' value to barplot #1878

@libmelo

Description

@libmelo

Recently, when I plotted a bar graph, I passed a 'width' to' barplot' function.
Such as sns.barplot(x='len', y="cnt", data=df, color="#6495ED", width=1)
But it told me I had passed the parameter. Then I found the class '_CategoricalPlotter' in 'categorical.py' assigned a 'width=.8' which was used by '_BarPlotter' of 'barplot'.
I think the 'barplot' could allow us to adjust the width of bar, even though we might not use it in general.
I used a 'if' statement to achieve my goal, but it seems not elegant. So I raised this issue.
seaborn 0.9.0 matplotlib 3.1.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions