|
From: Thor A. <ta...@to...> - 2013-01-16 11:16:26
|
On Wed, Jan 16, 2013 at 11:50:20AM +0100, Mikhail Kononets wrote: > Hi Thor Hi Mikhail, thanks for the help. > why not using 1/0 specification instead of '?': > > echo "set table; plot 'data' u 1:((strcol(3) eq 'B')? \$2 : 1/0)" | gnuplot > > # Curve 0 of 1, 5 points > # Curve title: "'data' u 1:((strcol(3) eq 'B')? $2 : 1/0)" > # x y type > 0 0 u > 0 0 u > 1 1 i > 2 4 i > 0 0 u I see, it does work better with NaNs, returning undefined for non-matching lines. The only issue is if I want to connect data points separated by one of the undefined lines, see for example: echo "plot 'data' u 1:((strcol(3) eq 'A')? \$2 : 1/0)" | gnuplot [...] -- best regards Thor Andreassen |