Colors can be defined using function. In this sample color of bars depends on sales value, and colors of pie sectors are alternative.