Credits | Overview | Plotting Styles | Commands | Terminals |
---|
This discussion applies only to the special plot style with table.
To avoid any style-dependent processing of the input data being tabulated (filters, smoothing, errorbar expansion, secondary range checking, etc), or to increase the number of columns that can be tabulated, use the keyword "table" instead of a normal plot style. In this case the output does not contain an extra column containing a flag i, o, u indicating inrange/outrange/undefined. The destination for output must first be specified with set table <where>. For example
set table $DATABLOCK1 plot <file> using 1:2:3:4:($5+$6):(func($7)):8:9:10 with table
Because there is no actual plot style in this case the columns do not correspond to specific axes. Therefore xrange, yrange, etc are ignored.
If a using term evaluates to a string, the string is tabulated. Numerical data is always written with format %g. If you want some other format use sprintf or gprintf to create a formatted string.
plot <file> using ("File 1"):1:2:3 with table plot <file> using (sprintf("%4.2f",$1)) : (sprintf("%4.2f",$3)) with table
To create a csv file use
set table "tab.csv" separator comma plot <foo> using 1:2:3:4 with table
[EXPERIMENTAL] To select only a subset of the data points for tabulation you can provide an input filter condition (if <expression>) at the end of the command. Note that the input filter may reference data columns that are not part of the output. Details of this feature may change in a future version.
plot <file> using 1:2:($4+$5) with table if (strcol(3) eq "Red") plot <file> using 1:2:($4+$5) with table if (10. < $1 && $1 < 100.) plot <file> using 1:2:($4+$5) with table if (filter($6,$7) != 0)