Palettes¶
Palette Scales¶
color_palette¶
fill_palette¶
gradient_color¶
gradient_fill¶
Palette Utilities¶
get_palette¶
- plotnine_extra.get_palette(palette='default', k=8)[source]¶
Return
kcolours sampled from a named palette.- Parameters:
palette (str or sequence) – Either one of the names in
plotnine_extra.palettes._ggsci, the strings"default"/"grey"/"viridis", a matplotlib colormap name, or a custom sequence of colours.k (int, default 8) – Number of colours to return. If
kis larger than the underlying palette, colours are linearly interpolated.
- Returns:
Hex colour strings of length
k.- Return type:
set_palette¶
change_palette¶
- plotnine_extra.change_palette(plot, palette)[source]¶
Alias of
set_palette().