boxwhisker.php
Back to Chart Graphics
setPlotArea(50, 25, 450, 200)->setGridColor(0xc0c0c0, 0xc0c0c0);
# Add a title to the chart
$c->addTitle("Computer Vision Test Scores");
# Set the labels on the x axis and the font to Arial Bold
$c->xAxis->setLabels($labels)->setFontStyle("Arial Bold");
# Set the font for the y axis labels to Arial Bold
$c->yAxis->setLabelStyle("Arial Bold");
# Add a Box Whisker layer using light blue 0x9999ff as the fill color and blue (0xcc) as the line
# color. Set the line width to 2 pixels
$c->addBoxWhiskerLayer($Q3Data, $Q1Data, $Q4Data, $Q0Data, $Q2Data, 0x9999ff, 0x0000cc
)->setLineWidth(2);
# Output the chart
$viewer = new WebChartViewer("chart1");
$viewer->setChart($c, SVG);
# Include tool tip for the chart
$viewer->setImageMap($c->getHTMLImageMap("", "",
"title='{xLabel}: min/med/max = {min}/{med}/{max}\nInter-quartile range: {bottom} to {top}'"));
?>
Box-Whisker Chart (1)
Box-Whisker Chart (1)
renderHTML(); ?>