我正在尝试将图形保存为jpeg格式,但由于某些原因,我无法使其工作。我正在按照Manning Gnuplot中的示例进行操作,但在我重新绘制时似乎没有创建jpeg。下面是代码,如果有人能指出我哪里错了,我会很感激的。
gnuplot> plot sin(x)
gnuplot> set terminal jpeg
Terminal type set to 'jpeg'
Options are 'nocrop font "arial,12" fontscale 1.0 size 640,480 '
gnuplot> set output "c:\Users\*****\Desktop\sinxplot.jpeg"
gnuplot> replot
gnuplot> set terminal wxt enhanced
Terminal type set to 'wxt'
Options are '0 enhanced'
gnuplot> set output
gnuplot> 仅供参考,即时消息使用版本4.6修补程序级别0
发布于 2012-05-14 02:41:31
gnuplot在字符串中使用\作为转义字符,因此这可能会弄乱您的路径。尝试使用单引号而不是双引号,或者使用\\作为路径分隔符。
(哦,顺便说一句: jpeg并不是很适合绘图,因为它的压缩算法会产生伪影,png在这里要好得多。)
https://stackoverflow.com/questions/10574074
复制相似问题