Pest control call-outs

The code below is the source for this graph.

<?php
// Pest control call-outs
require_once 'SVGGraph/autoloader.php';

$settings = [
  'auto_fit' => true,
  'back_colour' => '#eee',
  'back_stroke_width' => 0,
  'back_stroke_colour' => '#eee',
  'stroke_colour' => ['#600', '#900'],
  'stroke_width' => 2,
  'axis_colour' => '#333',
  'axis_overlap' => 2,
  'grid_colour' => '#666',
  'label_colour' => '#000',
  'axis_font' => 'Arial',
  'axis_font_size' => 10,
  'pad_right' => 20,
  'pad_left' => 20,
  'minimum_grid_spacing' => 20,
  'show_subdivisions' => true,
  'show_grid_subdivisions' => true,
  'grid_subdivision_colour' => '#ccc',
  'marker_type' => 'circle',
  'marker_size' => 4,
  'marker_colour' => 'red',
  'structure' => ['key' => 0, 'value' => 1],
];

$width = 670;
$height = 300;
$type = 'ParetoChart';
$values = [
  ['Ants', 23249],
  ['Bedbugs', 13698],
  ['Birds', 3786],
  ['Cockroaches', 17217],
  ["Other\nInsects", 35906],
  ["Other\nMammals", 8442],
  ['Mice', 121127],
  ['Rats', 278866],
  ['Wasps', 167023],
];

$colours = [ ['red', 'yellow'], ['blue', 'white'], ];

$graph = new Goat1000\SVGGraph\SVGGraph($width, $height, $settings);
$graph->colours($colours);
$graph->values($values);

$graph->render($type);

Please note: the source code above comes from a script used to generate one of the example graphs on the site. This is simply a wrapper page to apply highlighting and make the source code easier to read, so there is no content here to describe what the source code is doing.