Chart (experimental) example

Column chart

How it looks (preview)

Hats owned

This chart shows page views for January 2015.
This chart is a visual representation of the data available in the table.
Skip to "Hats owned" data table
View data as a table
Data table for "Hats owned"
Jon Ash James Phil
Hats owned 3 1 1 2

How to call this example

<%= render "govuk_publishing_components/components/chart", {
  chart_heading: "Hats owned",
  h_axis_title: "Day",
  v_axis_title: "Views",
  chart_overview: "This chart shows page views for January 2015.",
  chart_type: "column",
  hide_legend: true,
  keys: [
    "Jon",
    "Ash",
    "James",
    "Phil"
  ],
  rows: [
    {
      label: "Hats owned",
      values: [
        3,
        1,
        1,
        2
      ]
    }
  ]
} %>