1
|
{
|
2
|
"signals": [
|
3
|
{},
|
4
|
{},
|
5
|
{
|
6
|
"name": "detailDomain",
|
7
|
"update": "[time(data('range')[0].dateMin), time(data('range')[0].dateMin) + (timeWindow * arrowCount)] "
|
8
|
},
|
9
|
{
|
10
|
"name": "minMaxRange",
|
11
|
"update": "time(data('range')[0].dateMax) - time(data('range')[0].dateMin)"
|
12
|
},
|
13
|
{
|
14
|
"name": "selectionWidth",
|
15
|
"update": "floor((arrowCount * timeWindow * width) / minMaxRange)"
|
16
|
}
|
17
|
|
18
|
],
|
19
|
"marks": [
|
20
|
{
|
21
|
"marks": [
|
22
|
{
|
23
|
"marks": [
|
24
|
{
|
25
|
"type": "symbol",
|
26
|
"from": {
|
27
|
"data": "table"
|
28
|
},
|
29
|
"encode": {
|
30
|
"enter": {
|
31
|
"tooltip": {
|
32
|
"signal": "{title: timeFormat(datum.dateTime, '%A, %e. %B %Y, %X') }"
|
33
|
}
|
34
|
},
|
35
|
"hover": {
|
36
|
"fill": {
|
37
|
"value": "red"
|
38
|
}
|
39
|
},
|
40
|
"update": {
|
41
|
"shape": {
|
42
|
"value": "arrow"
|
43
|
},
|
44
|
"size": {
|
45
|
"value": 700
|
46
|
},
|
47
|
"x": {
|
48
|
"scale": "xDetail",
|
49
|
"field": "dateTime"
|
50
|
},
|
51
|
"y": {
|
52
|
"signal": "detailHeight / 2"
|
53
|
},
|
54
|
"angle": {
|
55
|
"field": "value"
|
56
|
},
|
57
|
"color": {
|
58
|
"value": "both"
|
59
|
},
|
60
|
"strokeWidth": {
|
61
|
"value": 1
|
62
|
},
|
63
|
"fill": {
|
64
|
"value": "steelblue"
|
65
|
}
|
66
|
}
|
67
|
}
|
68
|
}
|
69
|
]
|
70
|
}
|
71
|
]
|
72
|
},
|
73
|
{
|
74
|
"signals": [
|
75
|
{
|
76
|
"update": "[0,selectionWidth]"
|
77
|
}
|
78
|
],
|
79
|
"marks": [
|
80
|
{},
|
81
|
{},
|
82
|
{},
|
83
|
{
|
84
|
"type": "symbol",
|
85
|
"from": {
|
86
|
"data": "table"
|
87
|
},
|
88
|
"encode": {
|
89
|
"update": {
|
90
|
"size": {
|
91
|
"value": 10
|
92
|
},
|
93
|
"x": {
|
94
|
"scale": "xOverview",
|
95
|
"field": "dateTime"
|
96
|
},
|
97
|
"y": {
|
98
|
"signal": "overviewHeight / 2"
|
99
|
},
|
100
|
"color": {
|
101
|
"value": "both"
|
102
|
},
|
103
|
"strokeWidth": {
|
104
|
"value": 1
|
105
|
},
|
106
|
"fill": {
|
107
|
"value": "steelblue"
|
108
|
}
|
109
|
}
|
110
|
}
|
111
|
}
|
112
|
]
|
113
|
}
|
114
|
]
|
115
|
}
|