1
votes

I'm trying to plot my data which is in 'x y value' format using dashed lines. The dashed linetype I set up works with simple functions I give but when I use it on my own data it uses crosses instead of the dashed line.

I am using qt terminal on a mac running Gnuplot version 5.0.

my code:

set linetype 1 dashtype '-  -'
plot 'results.txt' lt 1

This produces the following plot:

results_plot

Any idea why gnuplot doesn't use my dash type?

1

1 Answers

0
votes

Plotting functions has different defaults (lines, show style function) than plotting data (points, show style data).

Either set the plotting style directly like

set linetype 1 dashtype '-  -'
plot 'results.txt' lt 1 with lines

Or set the desired style globally with

set style data lines