Pull out color select from curvechart as a separate function