gnuplot: How to plot each line of a data file as Y and incremental X

前端 未结 2 539
我寻月下人不归
我寻月下人不归 2020-12-30 03:05

I have a data file containing 30 columns and N rows. Each rows correspond to 30 values of function f(x) for x={1,...,30}. The data file has following pattern:



        
相关标签:
2条回答
  • 2020-12-30 03:36

    UPDATED based on @Christoph's comment:

    plot for [i=2:30] 'data.dat' using (i-1):(column(i)) with linespoint
    
    0 讨论(0)
  • 2020-12-30 03:44

    I found a solution:

    plot "data.dat" matrix every 1::1 with linespoint
    
    • matix indicates data file type by which the input file interpreted as matrix.
    • every 1::1 skip the first column
    0 讨论(0)
提交回复
热议问题