This is a six part series, taking you through stages of designing and creating reusable visualizations with d3.js
All visualizations have the same functionality, showcase the individual points with a bar chart and sum up the selected bars.
Part 1. This is showcasing a prototype visualization made solely with d3.js and vanilla javascript.
These are examples created for a talk (slides and video).
Cheers,
Miles @milr0c
xxxxxxxxxx
<head>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" href="https://littlesparkvt.com/flatstrap/assets/css/bootstrap.css"/>
<link type="text/css" rel="stylesheet" href="style.css"/>
<script src="https://d3js.org/d3.v3.min.js"></script>
</head>
<body>
<div class="row">
<div class="span2"><button class="btn btn-success" onclick="update()">update</button></div>
<div class="span2" id="sum">TOTAL: 0</div>
</div>
<div class="row" id="chart"></div>
<script src="src.js"></script>
</body>
</html>
Modified http://d3js.org/d3.v3.min.js to a secure url
https://d3js.org/d3.v3.min.js