Menu

#2609 For "plot" command, the index feature can not be used with stringcolumns.

None
closed-invalid
nobody
None
2023-05-26
2023-03-26
Anonymous
No

Gnuplot version 5.4 patchlevl 5, Windows
The index feature can not be used with stringcolumns.
For a datafile with two data sets, e.g. like this:


"comment" "comment"
"comment" "comment"
"comment" "comment"
"LabelX" "DataY"
"P1" 1
"P2" 2
"P3" 3

"comment" "comment"
"comment" "comment"
"comment" "comment"
"LabelX" "DataY"
"P1" 1.1
"P2" 2.2
"P3" 3.3


gnuplot> plot "FILE1" index 1 using "DataY":xticlabels(stringcolumn("LabelX")) skip 3 exit with linespoints
warning: no column with header "DataY"
^
all points y value undefined!

Discussion

  • mohit sharma

    mohit sharma - 2023-03-26

    The command line had a typo (an extra word "exit")
    It should be
    gnuplot> plot "FILE1" index 1 using "DataY":xticlabels(stringcolumn("LabelX")) skip 3 with linespoints

     
  • Karl Ratzsch

    Karl Ratzsch - 2023-03-26
    • Group: -->
    • Priority: -->
     
  • Karl Ratzsch

    Karl Ratzsch - 2023-03-26

    Data sets are separated by two blank lines in the data file, and the first set has index number zero.

     
    • Ethan Merritt

      Ethan Merritt - 2023-03-26

      Also "skip 3" is applied to the file as a whole, not to individual data blocks inside it.

       
  • Ethan Merritt

    Ethan Merritt - 2023-03-27
    • status: open --> open-invalid
     
  • Ethan Merritt

    Ethan Merritt - 2023-05-26
    • status: open-invalid --> closed-invalid
     

Log in to post a comment.

MongoDB Logo MongoDB