Help:Jqplotchart format
Jqplotchart format | |
---|---|
Displays aggregated numerical data as a bar, line, pie, or donut chart | |
Scenarios, examples, demos | |
Example: | Jqplotchart |
Collection | |
Further Information | |
Provided by: | Semantic Result Formats |
Added: | 1.8.0 |
Removed: | still supported |
Requirements: | none |
Format name: | jqplotchart |
Enabled? Indicates whether the result format is enabled by default upon installation of the respective extension. | Yes |
Authors: | James Hong Kong |
Categories: | charts |
Group: | , |
Table of Contents | |
The result format jqplotchart, displays aggregated numerical data as a bar, line, pie, or donut chart.
It is using the jqPlot Javascript library and starting with SRF 1.8, jqplotbar and jqplotpie have been merged into one class called jqplotchart which will handle all standard tasks that earlier jqplotbar and jqplotpie have managed. For compatibility reasons the format name jqplotbar and jqplotpie will still be available as aliases but point to format jqplotchart where the bar chart is set as default chart. Other chart layouts are available by using parameter ['layout'] which introduces two additional layouts, a line and a donut chart layout.
The change tried to accommodate compatibility as best as possible but some parameters have been either renamed or altered in their usage pattern to ensure similar behaviour across all layouts and in both classes ( jqplotchart and jqplotseries).
Parameters
⧼validator-describe-header-parameter⧽ | ⧼validator-describe-header-type⧽ | ⧼validator-describe-header-default⧽ | ⧼validator-describe-header-description⧽ |
---|---|---|---|
distribution | ⧼validator-type-boolean⧽ | no | Instead of displaying all values, count their occurrences, and show these. |
distributionsort | ⧼validator-type-string⧽ | none | Sort the value distribution by occurrence count. |
distributionlimit | ⧼validator-type-integer⧽ | no | Limit the value distribution to the count of only some values. |
aggregation | ⧼validator-type-string⧽ | subject | Specify to what the aggregation should relate to |
min | ⧼validator-type-integer⧽ | no | The minimum value to show on the Y-axis |
direction | ⧼validator-type-string⧽ | vertical | Specify the direction of a chart or graph |
charttitle | ⧼validator-type-string⧽ | ⧼validator-describe-empty⧽ | The title of the chart |
charttext | ⧼validator-type-string⧽ | ⧼validator-describe-empty⧽ | Descriptive chart text |
numbersaxislabel | ⧼validator-type-string⧽ | ⧼validator-describe-empty⧽ | The label for the numbers axis |
labelaxislabel | ⧼validator-type-string⧽ | ⧼validator-describe-empty⧽ | The label for the label axis |
height | ⧼validator-type-integer⧽ | 400 | Specify the height (in pixels) of a chart or graph |
width | ⧼validator-type-string⧽ | 100% | Specify the width (in pixels or percent) of a chart or graph |
smoothlines | ⧼validator-type-boolean⧽ | no | Apply a smoothing algorithm on line charts |
valueformat | ⧼validator-type-string⧽ | %d | Specify formatting rule for values |
ticklabels | ⧼validator-type-boolean⧽ | yes | Enable display of tick labels |
highlighter | ⧼validator-type-boolean⧽ | no | Display a data point highlighter |
theme | ⧼validator-type-string⧽ | ⧼validator-describe-empty⧽ | Select a grid theme |
filling | ⧼validator-type-boolean⧽ | yes | Individual filling option |
chartlegend | ⧼validator-type-string⧽ | none | Chart legend position |
datalabels | ⧼validator-type-string⧽ | none | Chart/graph data labels |
colorscheme | ⧼validator-type-string⧽ | ⧼validator-describe-empty⧽ | Select a color scheme |
chartcolor | ⧼validator-type-string⧽ | ⧼validator-describe-empty⧽ | Assign individual chart colors |
class | ⧼validator-type-string⧽ | ⧼validator-describe-empty⧽ | Specify an additional cascading style sheet class |
charttype | ⧼validator-type-string⧽ | bar | Available chart type |
Parameter values
As a list of values cannot be listed yet (see also here), here are some options what parameter values can be chosen, e.g. direction=horizontal
.
- direction: vertical, horizontal
- charttype: bar, donut, line, pie
- datalabels: none, value, label, percent
Changes deployed with SRF 1.8
- Added donut and line chart layout
- Added parameter [class], allows to add CSS characteristics
- Added parameter [charttext], a text field for an explanatory chart text
- Added parameter [smoothlines], applies a smoothing algorithm (only applied to the line chart)
- Added parameter [theme], a basic theming support for commonly styled attributes (vector, simple)
- Added parameter [colorscheme], option for an easy selection of pre-defined colours schemes
- Added parameter [datalabels], displays individual data as ( 'none', 'value', 'label', 'percent')
- Changed parameter [bardirection] to [direction] to accommodate overall changes
Examples
No best practices assigned to this printer.
Distribution
The value distribution is supported as well with jqplotchart as it was with jqplotbar and jqplotpie.
Notes
Reasons for the re-factoring effort was to ensure that the jqplot printer and its JavaScript plug-ins are used entirely throughout the ResourceLoader, eliminate identical code among jqplotbar and jqplotpie classes, and make use of the same JavaScript for both jqplotseries and jqplotchart class.
Property "Namespace" has a restricted application area and cannot be used as annotation property by a user.Property "Docinfo editor" (as page type) with input value "User:>Planetenxin" contains invalid characters or is incomplete and therefore can cause unexpected results during a query or annotation process.