Menu

#2772 gnuplot 6.x no data plotted after NaN with lc palette z

None
closed-fixed
nobody
2025-06-04
2025-03-06
theozh
No

The simple script which worked fine with gnuplot 5.x "fails" since gnuplot>=6.0.0

reset session

$Data <<EOD
 0    0.0
 1    0.1
 2    NaN
 3    0.3
 4    0.4
 5    0.5
 6    0.6
 7    0.7
EOD
set label 1 at graph 0.05, graph 0.95 sprintf("gnuplot %.1f.%s",GPVAL_VERSION, GPVAL_PATCHLEVEL)
plot $Data u 1:2:2 w l lw 4 lc palette z

The reason seems to be the NaNin the data together with lc palette z. If I remove the one or the other it works also in gnuplot>=6.0.0.
Apparently, gnuplot>=6.0.0 will not plot anything after a NaNappeared in the column which is used for z.
Not sure if this is a feature... at least in 5.x it worked as expected, but the behaviour in 6.x is somehow unexpected.

2 Attachments

Discussion

  • theozh

    theozh - 2025-03-06

    well, set datafile missing NaN will draw a continuous line both in 5.2.8 and 6.0.2, but how to get the graph with a break in 6.0.2?

     
  • Ethan Merritt

    Ethan Merritt - 2025-03-07
    • status: open --> pending-fixed
    • Group: -->
    • Priority: -->
     
  • Ethan Merritt

    Ethan Merritt - 2025-06-04
    • Status: pending-fixed --> closed-fixed
     

Log in to post a comment.