1

the following data sets are generated from program:

1 **1 0.11111**
1 **2 0.22222**
1 **3 0.33333**
1 **4 0.44444**
2 1 0.00185
2 2 0.00005
2 3 0.12355
2 4 0.68124
3 1 0.54875
3 2 0.62155
3 3 0.35895
3 4 0.41588

My question: How do I plot the first 4 row(bold) in 2-dimensional figure? i.e. the following point should be plotted:

(1, 0.11111) 
(2, 0.22222) 
(3, 0.33333) 
(4, 0.44444)

I know I can use "index" directive to plot multiple data sets, if so, double blank lines must come up from the file (in order to distinguish data sets). But I don't want any blank lines to come up. thanks

1
  • 1
    If the selection criterion for the lines you want to plot is not a fixed number of line but some value on each line, e.g. first value equals 1, then see stackoverflow.com/questions/36926994/… Commented May 10, 2016 at 14:30

1 Answer 1

0

you can use every ::0::3 to plot up to the 4th row: Gnuplot plotting data from a file up to some row, and using 2:3 to plot using the 2nd and 3rd column.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.