Ensuring that the color range is only created once.
Allowing for different color scale functions.