【问题标题】:One big and two small plots in multiplot gnuplotmultiplot gnuplot中的一大块和两块小块
【发布时间】:2016-01-17 20:07:25
【问题描述】:

我正在尝试使用 gnuplot(版本 5.0.1)的多图模式在同一画布上绘制三个不同的图

我希望以特定方式排列这些图:最终图应显示 2 行,图 A 在上排,而图 B 和 C 应并排显示在下排,就像下排一样我们有类似的东西:

"set multiplot layout 1,2"

如何做到这一点? 提前致谢

【问题讨论】:

    标签: gnuplot


    【解决方案1】:

    您需要使用最“精致”的网格进行多图,在本例中为 2x2,然后指定每个图的大小。

    set multiplot layout 2,2
    set size 1,0.5 # the first one has to be larger
    plot sin(1*x)
    set multiplot next # we want to skip the second (upright position)
    set size 0.5,0.5 # the second and third have to be 0.5x0.5 
    plot sin(2*x)
    plot sin(3*5)
    unset multiplot
    

    或者按照这里的建议https://stackoverflow.com/a/15906085/2743307 这样做可能更简单upwards(6 行而不是 8 行!)但是您必须以相反的顺序指定绘图:

    set multiplot layout 2,2 upwards
    plot sin(3*x)
    plot sin(2*x)
    set size 1,0.5
    plot sin(1*x)
    unset multiplot
    

    【讨论】:

    • 不幸的是,设置大小对我没有帮助。如果我尝试使其中一个图的大小非常小,它会在画布上的某个地方显示我不想要的图。你能告诉我如何让这些情节之一完全不可见吗?
    • 终于成功了!非常感谢。不过我很想看看解释。
    猜你喜欢
    • 1970-01-01
    • 2017-12-11
    • 2015-02-28
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多