Gnuplot: Colour proportional to y-value for builtin functions -


does know of easy way plot, say, sin(x), such colour changes depending on y-value?

set palette defined (0 "blue", 1 "green") plot sin(x) lc palette frac abs(sin(x)) 

also doesn't work!

any ideas?

thanks.

you can try use special filename '+' internally generates list of values (x values $1) , use values plot want using third column play palette.

set palette defined (0 "blue", 1 "green") plot '+' u ($1):(sin($1)):(abs(sin($1))) lines palette 

snapshoot of solution


Comments

Popular posts from this blog

What can cause "Required Package 'IndyCore' not found" when compiling a Delphi 2010 project? -

Change the color of an oval at click in Java AWT -