pygal

Documentation

Metadata

Labels

You can add per value metadata like labels, by specifying a dictionary instead of a value:

chart = pygal.Bar()
chart.add('Red', [{'value': 2, 'label': 'This is red'}])
chart.add('Green', [{'value': 4, 'label': 'This is green'}])
chart.add('Yellow', 7)
chart.add('Blue', [{'value': 5}])
chart.add('Violet', [{'value': 3, 'label': 'This is violet'}])
chart.render()