GnuPlot: Unterschied zwischen den Versionen

Aus Info-Theke
Zur Navigation springen Zur Suche springen
(Die Seite wurde neu angelegt: „Kategorie:DesktopApplikation = Beispiel = <pre>unset output set terminal png set output "statistic/wb-06.2016-02-18.cpu.png" set term png size 800, 800 se…“)
 
 
Zeile 4: Zeile 4:
<pre>unset output
<pre>unset output
set terminal png
set terminal png
set output "statistic/wb-06.2016-02-18.cpu.png"
set output "example/cpu.png"
set term png size 800, 800
set term png size 800, 800
set origin 0,0
set origin 0,0
Zeile 19: Zeile 19:
   '' using 1:3 with lines title 'Cpu usage %sys', \
   '' using 1:3 with lines title 'Cpu usage %sys', \
   '' using 1:4 with lines title 'Cpu usage %I/O wait'
   '' using 1:4 with lines title 'Cpu usage %I/O wait'
</pre>
== Die Daten dazu ==
<pre>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
...
</pre>
</pre>

Aktuelle Version vom 25. Februar 2016, 12:32 Uhr


Beispiel[Bearbeiten]

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[Bearbeiten]

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
...