MediaWiki User Guide/Graphs

MediaWiki has graph extension that allows to enter data into the wiki markup and have a graph rendered automatically as a raster image. Many wikis have Graph:Chart template that encapsulates the raw markup for the graphs.

A mimimal example of a line chart:


A bar chart with dimensions, axis titles, a grid that shows values above the bars and setting of a bar color:

 |xAxisTitle=Axis X|yAxisTitle=Axis Y

A line chart with x-axis values of the type date and x-axis labels at an angle:

 |xAxisFormat=%b %e

A line chart with two data series with line colors set and a legend:

 |y1Title=x squared
 |y2Title=x ^ 3

A semilog line chart, that is, one with logarithmic scale of the y-axis:

 |x=1, 2, 3, 4, 5, 6, 7, 8, 9, 10
 |y=3, 7, 20, 55, 148, 403, 1097, 2981, 8103, 22026

A pie chart with colors, values shown in the chart and a legend showing the x values:

 |colors=#66C, #C66, #6C6, #CC6, #C6C, #6CC
 |x=Milk, Honey, Bread, Rice, Cheese
 |y=100, 200, 150, 300, 50