From: Alan G I. <ala...@gm...> - 2011-07-31 14:05:33
|
On 7/30/2011 12:03 AM, Alan G Isaac wrote: > I'd like to pick the color for each line > based on its parameter value by mapping > possible parameter values to the colors > in a color map (e.g., gist_rainbow), > retrieving colors one at a time (based > on the parameter value for a line). As far as I can tell, the answer is the following. 1. scale the parameter to fall in (0,1) 2. get a color (rgba tuple) as cm.gist_rainbow(scaled_param) 3. plot using that color This works. Cheers, Alan Isaac |