相关疑难解决方法(0)

使用gnuplot进行堆叠直方图

我正在尝试使用以下数据创建堆叠直方图:

8.01    1   5   1   
8.02    3   5   1
8.03    4   4   1
8.04    3   4   1
8.05    1   2   1
Run Code Online (Sandbox Code Playgroud)

我试图改编第四个例子中的脚本,现在我正在使用它:

set title "Test"
set key invert reverse Left outside
set key autotitle columnheader
set style data histogram
set style histogram rowstacked
set style fill solid border -1
set boxwidth 0.75

plot 'test.dat' using 2:xtic(1),  '' using 2 title 'Col1', '' using 3 title 'Col2', '' using 4 title 'Col3'
Run Code Online (Sandbox Code Playgroud)

我复制的部分我不确定using 2:xtic(1).我知道这使得它使用xtic值作为第一列,这就是我想要的.但我不知道这using 2部分代表什么.这是脚本生成的屏幕截图: …

gnuplot histogram

9
推荐指数
1
解决办法
1万
查看次数

标签 统计

gnuplot ×1

histogram ×1