GnuPlot

Aus Info-Theke
Version vom 25. Februar 2016, 12:32 Uhr von Hamatoma (Diskussion | Beiträge) (→‎Beispiel)
(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Zur Navigation springen Zur Suche springen


Beispiel

unset output
set terminal png
set output "example/cpu.png"
set term png size 800, 800
set origin 0,0
set multiplot
set title "CPU-Usage"
set size 1,0.4
set origin 0,0.6
set timefmt "%H:%M"
set xdata time
set format x "%H:%M"
set yrange [0:*]
plot 'example/cpu.data' using 1:($2+$3+$4) with lines title 'cpu usage %', \
  '' using 1:2 with lines title 'Cpu usage %userland', \
  '' using 1:3 with lines title 'Cpu usage %sys', \
  '' using 1:4 with lines title 'Cpu usage %I/O wait'

Die Daten dazu

time user sys iowait idle
00:05 4.12 0.43 0.01 0.00 2
00:10 4.64 0.45 0.01 0.00 4
00:15 3.50 0.36 0.01 0.00 5
...