From 8fe076735300d276a8a362ae204808aa99f44308 Mon Sep 17 00:00:00 2001 From: Paul J R Date: Sun, 27 Oct 2013 17:33:32 +1100 Subject: [PATCH] change graph a bit --- src/graphit/make_graphs.php | 37 ++++++++++++++++++++----------------- 1 files changed, 20 insertions(+), 17 deletions(-) diff --git a/src/graphit/make_graphs.php b/src/graphit/make_graphs.php index 74c5208..575fccf 100644 --- a/src/graphit/make_graphs.php +++ b/src/graphit/make_graphs.php @@ -1,5 +1,8 @@ $val) { @@ -95,30 +98,30 @@ $options = array( "-h","300", "-l","-1", "--end","$end_time_4", -"DEF:4hr_jit=first_4_hours.rrd:jitter:AVERAGE", -"LINE2:4hr_jit#00FF00" +"DEF:".$time_lapse_start."hr_jit=first_4_hours.rrd:jitter:AVERAGE", +"LINE2:".$time_lapse_start."hr_jit#00FF00" ); // graph of jit -rrd_graph("4hour_first_jit.png", $options); +rrd_graph($time_lapse_start."hour_first_jit.png", $options); // create first four hours graph of off $options = array( "--start","$time_begin", "-w","600", "-h","300", -"-l","-1", +"-l","-1000", "--end","$end_time_4", -"DEF:4hr_jit=first_4_hours.rrd:offset:AVERAGE", -"LINE2:4hr_jit#00FF00" +"DEF:".$time_lapse_start."hr_jit=first_4_hours.rrd:offset:AVERAGE", +"LINE2:".$time_lapse_start."hr_jit#00FF00" ); // graph of offset -rrd_graph("4hour_first_off.png", $options); +rrd_graph($time_lapse_start."hour_first_off.png", $options); -$time_last_four = $time_end-(3600*4); +$time_last_four = $time_end-(3600*$time_lapse_end); // do the last four hour graphs // create first four hours graph of jit @@ -127,12 +130,12 @@ $options = array( "-w","600", "-h","300", "--end","$time_end", -"DEF:4hr_jit=all_data.rrd:jitter:AVERAGE", -"LINE2:4hr_jit#00FF00" +"DEF:".$time_lapse_end."hr_jit=all_data.rrd:jitter:AVERAGE", +"LINE2:".$time_lapse_end."hr_jit#00FF00" ); // graph of jit -rrd_graph("4hour_last_jit.png", $options); +rrd_graph($time_lapse_end."hour_last_jit.png", $options); // create first four hours graph of off $options = array( @@ -140,10 +143,10 @@ $options = array( "-w","600", "-h","300", "--end","$time_end", -"DEF:4hr_jit=all_data.rrd:offset:AVERAGE", -"LINE2:4hr_jit#00FF00" +"DEF:".$time_lapse_end."hr_jit=all_data.rrd:offset:AVERAGE", +"LINE2:".$time_lapse_end."hr_jit#00FF00" ); // graph of offset -rrd_graph("4hour_last_off.png", $options); +rrd_graph($time_lapse_end."hour_last_off.png", $options); ?> -- 1.7.0.4