Basically, I want to combine http://t16web.lanl.gov/Kawano/gnuplot/datafile2-e.html#7.4 and http://t16web.lanl.gov/Kawano/gnuplot/datafile2-e.html#7.2. I'm trying to get a gnuplot script with embedded plaintext data points to plot using three different colours all in one plot command, like so:
plot \
"-" index 0 title "waveform" with lines, \
"-" index 1 title "-trig" with lines, \
"-" index 2 title "+trig" with lines
1418 -0.04
1419 -0.04
1420 +5.28
1421 +5.20
1422 +5.16
1418 3.66
1422 3.66
1418 3.86
1422 3.86
end
However, it just displays the three blocks in one colour and throws an error on the second and third index commands.
Never mind, I finally guessed it into working:
plot \
"-" title "" with lines, \
"-" title "-trig" with lines, \
"-" title "+trig" with lines
1418 -0.04
1419 -0.04
1420 +5.28
1421 +5.20
1422 +5.16
end
1418 3.66
1422 3.66
end
1418 3.86
1422 3.86
end
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With