gnuplot filledcurves

本文详细记录了使用gnuplot绘制filledcurves图表时遇到的不显示边线问题,并提供了具体的绘图命令及数据样例。通过调整命令参数,最终实现了带有边线的filledcurves图表绘制。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

完整的作图过程,数据,最后结果如下所示,其中数据只列出了一部分:

set term pdf
set output "f11_cpu.pdf"
set grid
set title "CPU Total for Insert MongoDB"
set xlabel "Time (second)"
set ylabel "CPU%"

set xrange [0:300]
set yrange [0:100]
set key horizontal

set style data filledcurves
set style fill transparent pattern 1
plot "f11_cpu.txt" using 1:2 with filledcurves xy=0,0 lw 1 title "User%", '' using 1:2: 3 with filledcurves xy=0,0 lw 1 title "Sys%", '' using 1:3:4 with filledcurves lw 1 title "Wait%"

quit

 

1 22.4 29.2 29.3
2 50 66.6 66.7
3 52.6 70.7 70.8
4 55.6 75.2 75.3
5 50 76.7 77.1
6 51.5 74.9 75.0
7 50.1 77.1 77.3
8 53.4 79.2 79.3
9 53.6 75.7 75.8
10 55.1 74.6 74.7
11 57.1 76.8 76.9
12 50 72.9 73.0
13 54.1 73.5 73.8
14 53.8 71.5 71.6
15 51.9 69.5 69.6
16 53.7 73.8 73.9
17 54.3 77.1 77.3
18 57.7 77.3 77.4
19 58.9 77.4 77.5
20 54.5 73.1 73.2
21 53.8 71.6 71.9
22 51.3 68.0 68.2
23 27.3 39.2 39.4
24 23.5 31.8 31.9
25 17.5 22.7 22.7
26 32.9 43.6 44.0
27 54.6 73.9 74.0
28 58.4 77.8 77.9
29 57.4 78.4 78.5
30 57.1 78.1 78.8
31 58.4 77.9 78.0
32 57.5 76.9 77.0
33 56.8 77.7 77.9
34 60.1 80.2 80.3
35 58.5 76.8 76.9
36 57.7 76.1 76.2
37 55.9 73.8 73.9
38 56.2 76.1 76.2
39 57.6 77.9 78.0
40 58.6 81.2 81.4
41 56.3 80.6 80.7
42 55.8 80.2 80.4
43 60.8 82.7 82.8
44 57.6 80.4 80.5
45 56.1 78.8 79.0
46 57.3 78.4 78.5
47 55 75.5 75.7

 

 

 

 

 

用gnuplot画filledcurves图一直不显示边线,大家可以帮忙看下吗。我的画图命令和数据如下:

set term pdf

set output "test.pdf"

set xlabel "Time (second)"

set ylabel "CPU%"



set xrange [0:300]

set yrange [0:100]



set style data filledcurves

set style fill transparent pattern 1

plot "test.txt" using 1:2 with filledcurves xy=0,0 lw 1 title "User%", "" using 1:2:3 with filledcurves lw 1 title "Sys%"

exit

 

 

我的数据格式如下:

1  30  70

2  20  80

3  50  50

...

转载于:https://www.cnblogs.com/i4oolish/p/6278454.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值