Skip to content

Not easy to get colorbar tick mark locations #5792

@breedlun

Description

@breedlun

I can do color_bar.set_ticks(...) to set the tick mark locations, but I cannot find a corresponding color_bar.get_ticks(). Perhaps I am just missing it...

The only way I have found is to do color_bar.ax.get_yticks(), which returns tick marks locations, normalized to go from 0 to 1. I then have to do color_bar.get_clim() so I can unnormalize the tick mark locations. This seems like too much trouble. Furthermore, color_bar.ax.get_yticks() might not work if I happened to have a horizontal color bar.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions