forked from RDeconomist/prices
-
Notifications
You must be signed in to change notification settings - Fork 0
/
DistributionPubMeal
48 lines (37 loc) · 937 Bytes
/
DistributionPubMeal
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
{
"$schema": "https://vega.github.io/schema/vega-lite/v4.json",
"width": 500, "height": 400,
"data": {"url": "https://raw.githubusercontent.com/RDeconomist/prices/master/PubMealSwatheLong.csv"},
"transform": [
{
"filter": {
"field": "price",
"oneOf": ["10", "1020", "2030", "3040", "4050", "5060", "6070", "7080", "8090"]
}
}
],
"mark": {
"type":"area",
"orient":"vertical",
"opacity": 0.7
},
"encoding": {
"x": {
"field": "newDate",
"type": "temporal",
"title": null
},
"y": {
"aggregate":"sum",
"field": "p",
"type": "quantitative",
"title":"Price distribution"
},
"color": {
"legend":null,
"field": "price",
"scale": {"range": [null, "#D9D9F3", "#00BFFF", "#0276FD", "#000080", "#000080", "#0276FD", "#00BFFF", "#D9D9F3" ]}
},
"order": {"field": "price"}
}
}