Skip to content

Commit

Permalink
chore: update examples [CI]
Browse files Browse the repository at this point in the history
  • Loading branch information
GitHub Actions Bot committed Jan 26, 2025
1 parent 5bfb7f9 commit a21fed9
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 79 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions examples/compiled/arc_quantitative_stacked_theta.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
99 changes: 20 additions & 79 deletions examples/compiled/arc_quantitative_stacked_theta.vg.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,18 +9,9 @@
{
"name": "source_0",
"values": [
{
"segment": 1,
"value": 8
},
{
"segment": 2,
"value": 7
},
{
"segment": 3,
"value": 6
}
{"segment": 1, "value": 8},
{"segment": 2, "value": 7},
{"segment": 3, "value": 6}
]
},
{
Expand All @@ -31,14 +22,8 @@
"type": "stack",
"groupby": [],
"field": "segment",
"sort": {
"field": [],
"order": []
},
"as": [
"segment_start",
"segment_end"
],
"sort": {"field": [], "order": []},
"as": ["segment_start", "segment_end"],
"offset": "zero"
},
{
Expand All @@ -52,49 +37,22 @@
{
"name": "marks",
"type": "arc",
"style": [
"arc"
],
"from": {
"data": "data_0"
},
"style": ["arc"],
"from": {"data": "data_0"},
"encode": {
"update": {
"opacity": {
"value": 0.5
},
"stroke": {
"value": "#fff"
},
"innerRadius": {
"value": 20
},
"fill": {
"value": "#4c78a8"
},
"opacity": {"value": 0.5},
"stroke": {"value": "#fff"},
"innerRadius": {"value": 20},
"fill": {"value": "#4c78a8"},
"description": {
"signal": "\"segment: \" + (format(datum[\"segment\"], \"\")) + \"; value: \" + (format(datum[\"value\"], \"\"))"
},
"x": {
"signal": "width",
"mult": 0.5
},
"y": {
"signal": "height",
"mult": 0.5
},
"outerRadius": {
"scale": "radius",
"field": "value"
},
"startAngle": {
"scale": "theta",
"field": "segment_end"
},
"endAngle": {
"scale": "theta",
"field": "segment_start"
}
"x": {"signal": "width", "mult": 0.5},
"y": {"signal": "height", "mult": 0.5},
"outerRadius": {"scale": "radius", "field": "value"},
"startAngle": {"scale": "theta", "field": "segment_end"},
"endAngle": {"scale": "theta", "field": "segment_start"}
}
}
}
Expand All @@ -103,32 +61,15 @@
{
"name": "theta",
"type": "linear",
"domain": {
"data": "data_0",
"fields": [
"segment_start",
"segment_end"
]
},
"range": [
0,
6.283185307179586
],
"domain": {"data": "data_0", "fields": ["segment_start", "segment_end"]},
"range": [0, 6.283185307179586],
"zero": true
},
{
"name": "radius",
"type": "sqrt",
"domain": {
"data": "data_0",
"field": "value"
},
"range": [
20,
{
"signal": "min(width,height)/2"
}
],
"domain": {"data": "data_0", "field": "value"},
"range": [20, {"signal": "min(width,height)/2"}],
"zero": true
}
]
Expand Down

0 comments on commit a21fed9

Please sign in to comment.