Reputation:
I have a file with numbers:
1
4
9
...
I want to plot a depencency of the numbers from their order position in the file (points [(1,1); (2;4); (3; 9); ...]).
How can I do it with gnuplot?
Upvotes: 4
Views: 2566
Reputation: 4619
Try this :
plot "filename.txt" using ($0+1):1
$0 is the index of entries but it starts at 0 so we simlpy add 1 to it.
Tell me if this works for you!
Upvotes: 6