Menu

Gnuplot filled curves not showing properly

Help
Lesheng Li
2018-08-03
2018-08-04
  • Lesheng Li

    Lesheng Li - 2018-08-03

    Dear all,

    I am trying to plot a filled curve with Gnuplot. If I set the Y range to a large value, the filled curve is plotting just fine. However, when I use a small Y range, some part of the curve are not filling with colors.

    set terminal postscript color size 3.25,3.25 font "Helvetica, 8"
    set output "test.ps"
    set key at screen 0.95,0.70 right bottom
    set border lt 1 lc 0 lw 1
    set lmargin at screen 0.25
    set rmargin at screen 0.95
    set tmargin at screen 0.675
    set bmargin at screen 0.15
    set xlabel "X"
    set ylabel "Y"
    set xr [-1:2]
    set yr [0:160]
    set format x "%2.1f"
    set style fill transparent solid 0.4
    plot "data" w filledcurve x1 lt 1 lw 0.1 lc rgb "red"
    

    I have attache the data file and two figures here. Any comment or solution would be appreciated. Thank you all!

    Best,
    Lesheng Li

     

    Last edit: Lesheng Li 2018-08-03
  • Lesheng Li

    Lesheng Li - 2018-08-03

    Just confirmed it is a old version problem. Thanks.

     
  • Ethan Merritt

    Ethan Merritt - 2018-08-03

    It always helps if you specify what gnuplot version you are using.
    Your script and data work fine in gnuplot version 5.
    I assume you have something older than that.

     
    • Lesheng Li

      Lesheng Li - 2018-08-04

      Thank you Ethan!

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.