Reputation: 127
I am using a colorbar in matplotlib and because I want my graph to be more sensitive I take the square root of each value. This gives me square rooted values on my colorbar, but now I want to scale the ticks labels back to the real values. I am thusly having a hard time doing. I see that colorbar has a set_ticks function but I need to be able to get my ticks in the first place to do this generally. Is there an easy way to do this that I am not seeing, or some other way around this?
Upvotes: 5
Views: 1191
Reputation: 688
Calling the locator for the colorbar instance should return the tick locations.
colorbar.locator()
.
Upvotes: 4