Linux 有比 GNU 绘图更好的绘图工具吗?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/18265754/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-07 00:33:45  来源:igfitidea点击:

Any graph plotting tool better than GNU plot?

linuxgraphgnuplot

提问by Abhishek

I have used GNU-plot for quite a long time and the thing I didn't like about it the quality of graph it produces.

我已经使用 GNU-plot 很长时间了,但我不喜欢它生成的图形质量。

I admire the ease with which we can plot graphs in gnu-plot, but i wished that the resultant graph was better in terms of quality. For example: the thickness of lines, color quality etc..

我很欣赏我们可以轻松地在 gnu-plot 中绘制图形,但我希望生成的图形在质量方面更好。例如:线条粗细、颜色质量等。

So is there any tool that retains the ease-of-use of GNU PLOT but eliminates the quality issues?

那么有没有什么工具既保留了 GNU PLOT 的易用性又消除了质量问题呢?

[I like the graph that excel produces, but unfortunately its not on Linux...]

[我喜欢 excel 生成的图表,但不幸的是它不在 Linux 上......]

采纳答案by Bernhard

If you want another tool than gnuplot, then you are using it wrongly. I agree, the default colors and settings do not look that pretty, but you can so easily tweak it in your definition file ~/.gnuplot

如果您想要其他工具而不是gnuplot,那么您使用它是错误的。我同意,默认颜色和设置看起来不那么漂亮,但是您可以在定义文件中轻松调整它~/.gnuplot

set macros
png="set terminal png size 1800,1800 crop enhanced font \"/usr/share/fonts/truetype/times.ttf,30\" dashlength 2; set termoption linewidth 3"
eps="set terminal postscript fontfile \"/usr/share/fonts/truetype/times.ttf\"; set termoption linewidth 3;

set style line 1 linecolor rgb '#de181f' linetype 1  # Red
set style line 2 linecolor rgb '#0060ae' linetype 1  # Blue
set style line 3 linecolor rgb '#228C22' linetype 1  # Forest green

set style line 4 linecolor rgb '#18ded7' linetype 1  # opposite Red
set style line 5 linecolor rgb '#ae4e00' linetype 1  # opposite Blue
set style line 6 linecolor rgb '#8c228c' linetype 1  # opposite Forest green

Sample script:

示例脚本:

@png
set output "output.png"
plot x ls 1, -x ls 2, x**3 ls 3

And you have quite a nice graph already. Tweak linewidthand fontsizea bit, and you can do better than you would ever obtain with Excel.

你已经有了一个很好的图表。调整linewidthfontsize一点,你可以做得比你会不会用Excel获取。

回答by Sandman

You could give R a try. R has different graph plotting libraries. And it's very well explained in this SO question here - Relationship between plotting packages in R

你可以试试R。R 有不同的图形绘图库。这在这个 SO 问题中得到了很好的解释 - R中绘图包之间的关系

回答by Vincent Fourmond

You may give a try to ctioga2: http://ctioga2.sourceforge.net. I wrote it because I was unsatisfied with gnuplot. It does not have all gnuplot features, but in terms of graph quality, it does much better.

你可以试试ctioga2:http://ctioga2.sourceforge.net 。我写它是因为我对 gnuplot 不满意。它没有所有 gnuplot 功能,但在图形质量方面,它做得更好。

To migrate from gnuplot, you may be interested in the gnuplot versus ctioga2pages.

要从 gnuplot 迁移,您可能对gnuplot 与 ctioga2页面感兴趣。