You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

如何用gnuplot连接test.dat数据点并固定Y轴范围?

gnuplot 折线绘制与Y轴范围设置方案
  • 绘制连接数据点的折线:
    默认plot 'test.dat'仅显示离散点,只需在命令后添加绘图样式选项即可:

    • 若要同时显示数据点和折线,使用:
      plot 'test.dat' with linespoints
      
    • 若仅需要折线(隐藏数据点),使用:
      plot 'test.dat' with lines
      
  • 固定Y轴范围为0到1000:
    在执行plot命令前,先设置Y轴范围,再执行绘图命令:

    set yrange [0:1000]
    plot 'test.dat' with linespoints
    

    若想让该Y轴范围成为默认设置,可将set yrange [0:1000]写入gnuplot配置文件(通常为~/.gnuplot),下次启动gnuplot时会自动加载该配置。

内容的提问来源于stack exchange,提问作者Cheetaiean

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.18 04:05:14