Reputation: 31
I'm creating heatmaps and histograms using Plots.jl. E.g.,
heatmap(labels_x, labels_y, my_data_matrix)
2 questions:
How does one change the font for the tick labels on the color scale?
How does one change the range of the values in the color scale? (I know they automatically span the full range of values, but sometimes you want something different because, for example you want two heatmaps/histograms to have identical scales so they can be easily compared.)
One can, for example, change the font of the tick labels on the axes with
plot!(xtickfont=font(36, "Courier"))
but I would like to change the font of the ticks on the scale. (ztickfont does not work.)
The attributes are listed here: https://juliaplots.github.io/attributes/ I didn't see anything that appears to be what I want, but please point me to the right one if it's there. Thanks.
Upvotes: 3
Views: 1600
Reputation: 8044
As @tbreloff noted in his comment, the answer to question #2 is to use the clims
keyword. The answer to #1 is, that after https://github.com/JuliaPlots/Plots.jl/pull/1108 the tickfont in the colorbar is the same as the plot's tickfont, in the pyplot backend - we're looking to include this for the other backends as well.
Upvotes: 1