【问题标题】:How to add data from gnuplot to an existing file without overwiting the contents of said file如何将 gnuplot 中的数据添加到现有文件而不覆盖所述文件的内容
【发布时间】:2012-11-02 13:52:04
【问题描述】:

我有一些gnuplot代码如下:

gnuplot> h=1
gnuplot> a=2
gnuplot> set print "additional numbers.txt"
gnuplot> print h,a
gnuplot> set print

现在我想在不覆盖之前的条目的情况下向该文件添加更多数据。我可以在 C 中完成,但我想将所有内容保存在 1 个可以通过 gnuplot 运行的脚本中

希望你能帮忙。

【问题讨论】:

    标签: gnuplot


    【解决方案1】:

    使用append 标志:

    set print "additional_numbers.txt" append
    

    【讨论】:

    • help set print 中所述。
    猜你喜欢
    • 2022-01-22
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2014-03-07
    • 2015-04-29
    • 1970-01-01
    • 2017-05-15
    • 2012-07-24
    相关资源
    最近更新 更多