我经常在gnuplot
的命令行界面中绘制图形,就像这样:
gunuplot> plot sin(x) with linespoints pointtype 3
图表显示得很好。
今天,我将图表保存在一个 .png
文件中,如下所示:
gnuplot> set term png
gnuplot> set output "output.png"
gunuplot> plot sin(x) with linespoints pointtype 3
然后,在Ubuntu中我使用eog
打开output.png
,像这样:
$ eog output.png
我发现在eog
中显示的output.png
图片不如终端中绘制的好。
为什么会这样?保存output.png
前需要调整一些设置吗?
PS
我找到了一个解决方法,首先,
set term postscript
set output "output.ps"
然后在 Linux shell 中执行:
$ convert output.ps output.jpg
这种方式在某种程度上解决了我的问题。