-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
143 lines (117 loc) · 5.07 KB
/
index.html
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
<!DOCTYPE html>
<html lang="en">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link type="text/css" rel="stylesheet" media="screen" href="./css/style.css">
<script src="https://d3js.org/d3.v7.min.js"></script>
<title>Bicycle Counter Dashboard</title>
<script type="text/javascript" src="https://cdn.jsdelivr.net/jquery/latest/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datepicker/1.9.0/js/bootstrap-datepicker.min.js" integrity="sha512-T/tUfKSV1bihCnd+MxKD0Hm1uBBroVYBOYSk1knyvQ9VyZJpc/ALb4P0r6ubwVPSGB2GvjeoMAJJImBG12TiaQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap-datepicker/1.9.0/css/bootstrap-datepicker3.standalone.min.css" integrity="sha512-p4vIrJ1mDmOVghNMM4YsWxm0ELMJ/T0IkdEvrkNHIcgFsSzDi/fV7YxzTzb3mnMvFPawuIyIrHcpxClauEfpQg==" crossorigin="anonymous" referrerpolicy="no-referrer" />
<style type="text/css">
#tooltip {
position: absolute;
width: auto;
height: auto;
padding: 5px 5px;
color: white;
border:1px;
border-style: solid;
border-width: 1px;
border-color:white;
pointer-events: none;
text-align: left;
white-space: normal;
}
#tooltip.hidden {
display: none;
}
#tooltip p {
margin-top: 0;
margin-bottom: 0;
font-size: 12px;
line-height: 15px;
}
#tooltip::before {
content: "";
position: absolute;
top: 50%;
left: -12px;
margin-top: -6px;
border-width: 6px;
border-style: solid;
border-color: transparent white transparent transparent;
}
#tooltip::after {
content: "";
position: absolute;
top: 50%;
left: -10px;
margin-top: -5px;
border-width: 5px;
border-style: solid;
border-color: transparent black transparent transparent;
}
.form-spacing {
margin-top: 7px;
}
.table-padding-bottom {
margin-bottom: 60px;
}
</style>
</head>
<body>
<h1>Bike Traffic Dashboard</h1>
<div class="container">
<div class="input-daterange input-group" id="datepicker">
Select date range:
<input type="text" class="input-sm form-control" name="start" value="2022-08-26"/>
<span class="input-group-addon">to</span>
<input type="text" class="input-sm form-control" name="end" value="2022-11-19"/>
</div>
<form class="form-spacing">
Traffic direction:
<label><input type="radio" name="filterPreset" value="both" checked="true"> Both</label>
<label><input type="radio" name="filterPreset" value="in"> Northbound only</label>
<label><input type="radio" name="filterPreset" value="out"> Southbound only</label>
</form>
<form class="form-spacing">
Select data resolution:
<label></label><input type="radio" name="filterPreset" value="monthly"> monthly</label>
<label></label><input type="radio" name="filterPreset" value="weekly"> weekly</label>
<label></label><input type="radio" name="filterPreset" value="daily" checked="true"> daily</label>
<label></label><input type="radio" name="filterPreset" value="hourly"> hourly</label>
<label></label><input type="radio" name="filterPreset" value="30min"> 30 min</label>
<label></label><input type="radio" name="filterPreset" value="15min"> 15 min</label>
</form>
<h2>Bike traffic by date & time</h2>
<div id="tooltip" class="hidden">
<p><span id="tooltipText"></span></p>
</div>
<div id="barchart"></div>
<h2>Traffic summary on the selected dates</h2>
<div id="table"></div>
<h2>Daily traffic by day of week</h2>
<div id="boxplot-weekday"></div>
<h2>Hourly traffic by time of day</h2>
<div id="checkbox-container"></div>
<div id="boxplot-hourly"></div>
<b>This dashboard is open source and hosted on a
<a href="https://github.com/fenggroup/bike-counter-d3">GitHub repository.</a></b>
<br>
<br>
<b>Download the <a href="https://github.com/fenggroup/bike-counter-d3/tree/main/data">bike counter data</a></b>
<br>
<br>
</div>
<script src="./js/datepicker.js"></script>
<script src="./js/barchart.js"></script>
<script src="./js/table.js"></script>
<script src="./js/boxplot-weekday.js"></script>
<script src="./js/boxplot-hourly.js"></script>
<script src="./js/buttons.js"></script>
</body>
</html>