Color Update using set_UVC()

the colour parameter in set_UVC() for quivering requires a float array. How to construct an array of colours using float numbers?

color_float = np.array([[1.,0.,0.]])

Any help is appreciated.

Please see for a longer explanation. The very short version is:

from matplotlib.colors import Normalize
from import get_cmap

# class to map data to the required range
norm = Normalize(min=your_min, max=your_max)
# maps [0, 1] -> RGBA
cmap = get_cmap('viridis')

# put data in range [0, 1]
normed_data = norm(your_data)
# get array of RGBA
colour_array = cmap(normed_data)

Hopefully that helps!