deptharea.php
Back to Chart Graphics
setPlotArea(50, 30, 250, 150);
# Add a legend box at (55, 0) (top of the chart) using 8pt Arial Font. Set background and border to
# Transparent.
$c->addLegend(55, 0, false, "", 8)->setBackground(Transparent);
# Add a title to the x axis
$c->xAxis->setTitle("Network Load for Jun 12");
# Add a title to the y axis
$c->yAxis->setTitle("MBytes");
# Set the labels on the x axis.
$c->xAxis->setLabels($labels);
# Display 1 out of 2 labels on the x-axis. Show minor ticks for remaining labels.
$c->xAxis->setLabelStep(2, 1);
# Add three area layers, each representing one data set. The areas are drawn in semi-transparent
# colors.
$c->addAreaLayer($data2, 0x808080ff, "Server #1", 3);
$c->addAreaLayer($data0, 0x80ff0000, "Server #2", 3);
$c->addAreaLayer($data1, 0x8000ff00, "Server #3", 3);
# Output the chart
$viewer = new WebChartViewer("chart1");
$viewer->setChart($c, SVG);
# Include tool tip for the chart
$viewer->setImageMap($c->getHTMLImageMap("", "",
"title='{dataSetName} load at hour {xLabel}: {value} MBytes'"));
?>
Depth Area Chart
Depth Area Chart
renderHTML(); ?>