from colorspace import diverging_hsv
pal = diverging_hsv()
pal.colors(10)['#0000FF',
'#8282FF',
'#B2B2FF',
'#D5D5FF',
'#F2F2FF',
'#FFF2F2',
'#FFD5D5',
'#FFB2B2',
'#FF8282',
'#FF0000']
Documentation built with Python 3.11.10, pyp2qmd 0.1.1 and quarto 1.5.57 on GitHub.
diverging_hsv provides an HSV-based version of diverging_hcl. Its purpose is mainly didactic to show that HSV-based diverging palettes are less appealing, more difficult to read and more flashy than HCL-based diverging palettes.
See also: qualitative_hcl, sequential_hcl, diverging_hcl, divergingx_hcl, rainbow_hcl, heat_hcl, terrain_hcl, and rainbow.
diverging_hsv(h=[240, 0], s=1.0, v=1.0, power=1.0,
fixup=True, rev=False, *args,
**kwargs)
hlist of numerics
h is a str this argument acts like the palette argument (see palette input parameter).
sfloat, int
vfloat, int
powernumeric
fixupbool
revbool
*args
**kwargs
h1, h2, s, v.
Initialize new object, no return. Raises a set of errors if the parameters are misspecified. Note that the object is callable, the default object call can be used to return hex colors (identical to the .colors() method), see examples.
diverging_hsv.cmap(n=256, name='custom_hcl_cmap')
diverging_hsv.colors(n=11, fixup=None, alpha=None, **kwargs)
diverging_hsv.get(key)
diverging_hsv.hclplot(n=7, **kwargs)
diverging_hsv.name()
diverging_hsv.show_settings()
diverging_hsv.specplot(n=180, *args, **kwargs)
diverging_hsv.swatchplot(n=7, **kwargs)
['#0000FF',
'#8282FF',
'#B2B2FF',
'#D5D5FF',
'#F2F2FF',
'#FFF2F2',
'#FFD5D5',
'#FFB2B2',
'#FF8282',
'#FF0000']
['#0000FF',
'#8282FF',
'#B2B2FF',
'#D5D5FF',
'#F2F2FF',
'#FFF2F2',
'#FFD5D5',
'#FFB2B2',
'#FF8282',
'#FF0000']
# Manually modified palette from 'cyan' to 'orange'
diverging_hsv(h = [180, 30]).swatchplot(
n = 7, show_names = False, figsize = (5.5, 0.5))
