[gnuplot]使用gnuplot绘制Lattice

最近学习了gnuplot,  上手做了一个Lattice的脚本,这里只能显示2x2,如果使用其它脚本配合,就可以灵活的根据数据来显示。 下面这个是效果:

[gnuplot]使用gnuplot绘制Lattice_第1张图片


脚本(以2x2为例, 测试数据中含有两列), 其中要点是使用multi-plot模式,根据需要(第一行及第一列)显示标题即可。

unset xtic
unset ytic

set multiplot title "Polynomials" layout 2,2

set ylabel ''
set ylabel 'VMSize'
set xlabel ''
set title 'VMSize'
plot "testData.csv" using 1:1 title '' pt 7

set ylabel ''
set title 'VMData'
set xlabel ''
plot "testData.csv" using 1:2 title '' pt 7

set ylabel 'VMData'
set title ''
set xlabel ''
plot "testData.csv" using 2:1 title '' pt 7

set ylabel ''
set title ''
set xlabel ''
plot "testData.csv" using 2:2 title '' pt 7
unset multiplot


你可能感兴趣的:(gnuplot)