plot "datafilename" using 1:(strstrt(stringcolumn(3),"Blue")==1?$2:0/0) with
points linecolor rgb "blue", \
"" using 1:(strstrt(stringcolumn(3),"Red")==1?$2:0/0) with points linecolor
rgb "red", \
"" using 1:(strstrt(stringcolumn(3),"Green")==1?$2:0/0) with points
linecolor rgb "green"
if you could replace the color names by color indices you could
use a specially tailored color palette. this would reduce the above
command to
plot "datafilename" using 1:2:3 with points linecolor palette
Sara Khalatbari wrote:
>
> Hi again,
>
> So now I have a file that looks like this
>
> 1 4 Blue
> 5 7 Red
> 6 1 Green
> 1 3 Blue
> 8 3 Blue
> 9 2 Red
> 5 1 Green
> ...
>
> The colors are placed randomly, so it is not always like: Blue would
> appear
> on every 3rd line or so.
>
> I want it to just put the dots in different colors, How would I set that?
>
> Thank you,
> Sara
> ------------------------------------------------------------------------------
> Download Intel® Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> gnuplot-info mailing list
> gnu...@li...
> https://lists.sourceforge.net/lists/listinfo/gnuplot-info
>
>
--
View this message in context: http://old.nabble.com/How-to-add-colors--tp28264501p28264860.html
Sent from the Gnuplot - User mailing list archive at Nabble.com.
|