1

I have the following table:

/*   out.dat   */
0 1.856381821661646 0.511222553331535
1 -1.513297876716274 -0.795936395061944
2 -1.467599747901700 -0.746686307661924
3 -0.559071676029565 0.626769978902970
4 0.826490214782210 0.000000002133100
4 0.836812258049098 0.000000002119134
4 0.837038664701387 0.000000001783730
4 0.845692121312554 0.000000003032239
4 0.909049958675113 0.000000000193274
4 0.885434430828159 0.000000000194619
(...)

The second and third columns are the x/y values, where the first column is the label for the datapoints. I want all points with a 0 to have a distinguishable symbol, another symbol for all points with a 1, and so on.

So the pseudocode looks like this: plot "out.dat" using 2:3 with points [from 1. col] By the way, since I need around 30 different symbols, the palette option doesn't help much.

4

1 回答 1

1

You could use gnuplot's iteration:

plot for [i=0:30] 'out.dat' u 2:($1==i ? $3: NaN) w points pt i

Although I must say that hoping for 30 unique and easily distinguishable markers might be a bit of a stretch for most (all?) terminals...

于 2013-03-31T00:10:37.920 回答