Chart Code Block
Here are high level views of the basic syntax for the four chart types. The shorter examples include only the required elements, while the longer examples include some of the optional tags that you can use to customize the charts.
Notice that the block does not require a cPlan. If no cPlan is stated, the chart uses the same cPlan as the containing block.
NOTE: When multiple columns or dimensions are used, they are order dependent; all other tags are not.
Here is a high level view of the basic syntax of a bar-chart block.
bar-chart id = <string> { dimension <string> bar column = <string> }
Here is the high level view of the syntax of a customized bar-chart block.
bar-chart id = <string> { cplan <string> title <string> dimension <string> bar column = <string> bar column = <string> first <integer> background-color <string> legend-location <string> //OR hide-legend sort-column <string> //OR no-sort title-justification <string> }
Here is a high level view of the basic syntax of an hbar-chart block.
hbar-chart id = <string> { dimension <string> bar column = <string> }
Here is the high level view of the syntax of a customized hbar-chart block.
hbar-chart id = <string> { cplan <string> dimension <string> bar column = <string> bar column = <string> data-labels first <integer> background-color <string> legend-location <string> //OR hide-legend sort-column <string> //OR no-sort }
Here is a high level view of the basic syntax of a line-chart block.
line-chart id = <string> { dimension <string> line column = <string> }
Here is the high level view of the syntax of a customized line-chart block.
line-chart id = <string> { cplan <string> title <string> dimension <string> line column = <string> line column = <string> first <integer> background-color <string> legend-location <string> //OR hide-legend sort-column <string> //OR no-sort title-justification <string> }
Here is a high level view of the basic syntax of a pie-chart block.
pie-chart id = <string> { dimension <string> column column = <string> }
Notice that a pie-chart can only have one column.
Here is the high level view of the syntax of a customized pie-chart block.
pie-chart id = <string> { cplan <string> title <string> dimension <string> column column = <string> background-color <string> legend-location <string> //OR hide-legend title-justification <string> }
See also: