Skip to content

Small tips on the matplotlib tutorial #58

@timhoffm

Description

@timhoffm

Annotating bars

There is https://matplotlib.org/stable/api/_as_gen/matplotlib.axes.Axes.bar_label.html so that you don't have to roll your own annotate_bars() function anymore.

Boxplots
Instead of

    ax.boxplot(...)
    ax.set_xticklabels(labels)

use

    ax.boxplot(..., tick_labels=labels)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions