Status: | effective |
Progress: | 100% |
Version: | 1.4.0+ |
Help:Google pie format
Google pie format | |
---|---|
Produces a pie chart using the Google Charts API | |
Further Information | |
Provided by: | Extension "Semantic Result Formats" |
Added: | 1.4.0 |
Removed: | still supported |
Requirements: | none |
Format name: | googlepie |
Enabled? Indicates whether the result format is enabled by default upon installation of the respective extension. | no |
Authors: | Denny Vrandečić |
Categories: | charts |
Table of Contents | |
→ The creators of Semantic Result Formats have not control over and cannot take any responsibility in case of any misuse resulting from this!
The result format googlepie, part of extension "Semantic Result Formats"Provides additional formats for semantic queries, is used to produce bar charts using the Google Charts API.
Parameters[edit]
A fatal error occurred in the #smwdoc parser function
Usage[edit]
You use the same queries as usual, but make sure to add a printout statement with a property that is of type Number. All printouts of properties of type number will be taken for the visualization. The only further parameters are height
and width
. If not given, mostly sensible values are assumed.
You may want a pie chart to not show property values directly, but rather the popularity of different values of a property across the entire wiki; i.e. a numerical distribution. This is fairly easy to do; see here for how.
Example[edit]
- Syntax
{{#ask: [[Category:City]] [[Located in::Germany]] |?Population |format=googlepie }}
- Result
Enabling[edit]
This result format is not enabled by default on a wiki. To enable it add the following line to your "LocalSettings.php" file after the inclusion of Semantic MediaWiki and Semantic Result Formats:
$srfgFormats[] = 'googlepie';
Chart formats[edit]
These are the chart related result formats provided by Semantic MediaWiki and extensions to Semantic MediaWiki.