New features
The `colors.py` has been added, which provides a set of color generator functions for data representation.
colors.osc_line()
A function that creates an oscillator line with given parameters. Returns a numpy array with the oscillator line points.
The function has the parameters:
`points` The amount of points there should be on the line.
`tt` The trigonometry type. Can be 'sin' or 'cos'. Default is 'sin'.
`lin` The linearity. Default is 1.
`gauge` Maximum amplitude span of the oscillator. Default is 0.5.
`freq` The frequency of the oscillator. Default is 4.
`min_shift` A minimum shift of the oscillator baseline. Default is 0.1.
colors.color_generator()
Generates an array of colors from an RGB spectrum through the oscillator line function. Returns a numpy array with the color spectrum points in the form ((R,G,B), ...). If cdict is True a the output will instead be ((R,G,B), ...), dict.
The function has the parameters:
`n` Number of colors to generate.
`tt` The trigonometry type for the R, G, and B channels. Can be 'sin' or 'cos'. Default is ('sin', 'sin', 'sin').
`lin` Linearity for the R, G, and B channels. Default is (1, 1, 1).
`gauge` Maximum amplitude span of the oscillator for the R, G, and B channels. Default is (0.5, 0.5, 0.5).
`freq` Frequency of the oscillator for the R, G, and B channels. Default is (4, 4, 4).
`random` If True the color spectra are generated randomly. Default is False.
`rf` Upper frequency limit for the R, G, and B channels. Default is 10.
`boldness` Introduces a minimim baseline for the R, G, and B channels. A higher value streamlines the color spectrum, such that a more easily pleasing spectrum is obtained. A lower value makes the colors in the spectrum more easily distinguishable. Default is 0.1.
`rb` The boldness limit for the R, G, and B channels. Default is 0.4.
`cdict` If True a dictionary with the function parameters is generated in addition to the colors from the generated spectrum. Default is False.
colors.color_presets()
Gives n amount of colors from a chosen color preset. Returns a numpy array with the color spectrum points in the form ((R,G,B), ...).
The function has the parameters:
`n` The number of colors to generate.
`preset` The preset from which the colors are generated. If preset is -1, a figure with all different presets is generated instead. Default is -1.
colors.RandomColors
A random color preset generator class.
.generate()
Generate random color preset. Creates a figure with the generated colors and defines the color parameter dictionary as ´self.cdict´.
`sets` The number of presets to generate.
`n` The number of colors to generate in each preset.
`max_frequency` Upper frequency limit for the R, G, and B channels. Default is 10.
`max_boldness` The boldness variation lower limit for the R, G, and B channels. Default is 0.4.