Difference between revisions of "Template:Graph:CategoryPie"

From Public Play Space Community
Line 1: Line 1:
<graph>
{{Graph:Chart|width=100|height=100|type=pie|legend=Legende
{
|x=A,B,C,D,E,F,G,H,I|y1=100,200,150,300,100,100,150,50,200
  "$schema": "https://vega.github.io/schema/vega-lite/v4.json",
|y2=7,8,9,8,8,9,10,9,5|showValues=}}
  "description": "A simple bar chart with embedded data.",
  "data": {
    "values": [
      {"a": "A", "b": 28}, {"a": "B", "b": 55}, {"a": "C", "b": 43},
      {"a": "D", "b": 91}, {"a": "E", "b": 81}, {"a": "F", "b": 53},
      {"a": "G", "b": 19}, {"a": "H", "b": 87}, {"a": "I", "b": 52}
    ]
  },
  "mark": "bar",
  "encoding": {
    "x": {"field": "a", "type": "ordinal", "axis": {"labelAngle": 0}},
    "y": {"field": "b", "type": "quantitative"}
  }
}
 
</graph>

Revision as of 07:33, 19 May 2020