Chart Macro
This is a Radeox macro, bundled with all the XWiki products by default.
Macro developed by the XWiki Development Team.
This macro cannot currently be downloaded separately.
Macro developed by the XWiki Development Team.
This macro cannot currently be downloaded separately.
Chart Macro
The chart macro creates a PNG/SVG chart using data from a wiki table or another data source. This macro is not so easy to use directly (it has really a lot of parameters) so there is a work-in-progress charting wizard. For more samples see this special page.Usage
see exampleParameters definition
| Name | Optional | Allowed values | Default value | Description |
|---|---|---|---|---|
| type | false | area, bar, line, pie, time | The type of chart | |
| source | false | map | The data source used for the table | |
| type | false | table, object and objectid | In the sequel we only consider the more common case of table data sources. | |
| doc | true | document name | current document | The document that contains the source table |
| table_number | true | number | 0 (first table) | The position of the table in the document. Numbering starts at 0 and only radeox tables are counted. |
| range | true | * or of the form A4-C7 | * | The part of the table that is charted |
| decimal_symbol | true | char | period (.) | Usually comma (,) or period (.) |
| ignore_alpha | true | boolean | false | Whether all illegal characters in the data are ignored instead of considered errors |
| has_header_row | true | boolean | true | Whether the first raw is a header and should be used to name series |
| has_header_column | true | boolean | true | Whether the first column is a header and should be used to name series |
| series | true | columns or rows | columns | Whether the series are organized on rows or on columns |
| width | true | number | 400 | The width of the chart in pixels |
| height | true | number | 300 | The height of the chart in pixels |
| border_visible | true | boolean | false | |
| anti_alias | true | boolean | true | Antialiasing |
Example
{table}
Category | Sales ($)
Category 1 | 1000000
Category 2 | 500000
Category 3 | 500000
Total | = sum(B2:B4)
{table}
{chart:source=type:table;range:A1-B4|type=pie|title=pie in the sky}Result