From 58cea006d6b5b4c6c1962a0ba0fc59791ac03199 Mon Sep 17 00:00:00 2001 From: Gert Ingold Date: Mon, 10 Oct 2005 05:38:17 +0000 Subject: [PATCH] question 4.3.4: added explanation of 'equidistant colors' (suggested by J. Owens) git-svn-id: https://pyx.svn.sourceforge.net/svnroot/pyx/trunk/pyx@2514 069f4177-920e-0410-937b-c2a4a81bcd90 --- faq/pyxfaq.tex | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/faq/pyxfaq.tex b/faq/pyxfaq.tex index 091aba9f..8263dc6a 100644 --- a/faq/pyxfaq.tex +++ b/faq/pyxfaq.tex @@ -628,20 +628,26 @@ palette? \new} {If several data sets should be plotted in different colors, one can specify in \texttt{symbolattrs} and/or \texttt{lineattrs} a palette like \texttt{color.palette.Rainbow}. Equidistant colors are chosen spanning the -palette from one end to the other. In the following example, symbols vary in -form and change their color according to the rainbow palette at the same time -as the connecting lines: +palette from one end to the other. For example, for three data sets the +colors are chosen from the palette at $0., 0.5,$ and $1$. For the rainbow +palette, this would correspond to red, green, and blue, respectively. + +In the following example, symbols vary in form and change their color according +to the rainbow palette at the same time as the connecting lines: \begin{progcode} mystyle = [graph.style.symbol(graph.style.symbol.changecircle,\\ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~symbolattrs=[color.palette.Rainbow]),\\ ~~~~~~~~~~~graph.style.line(lineattrs=[color.palette.Rainbow])] \end{progcode} +See question~\ref{q:changelist} for a more complete example demonstrating +how to use this style definition. } \question{a}{How can I specify changing colors (or other attributes) for symbols or lines? \new} {} -{In \texttt{symbolattrs} and/or \texttt{lineattrs} so-called changelist can +{\label{q:changelist} +In \texttt{symbolattrs} and/or \texttt{lineattrs} so-called changelist can be used. As an example \begin{progcode} mystyle = graph.style.symbol(symbolattrs=\\ -- 2.11.4.GIT