This is the main code: https://gist.github.com/ndarville/7075823
<script src="d3.min.js?v=3.2.8"></script>
<script type="text/javascript"charset="utf-8">
d3.text("data.csv", function(data) {
var parsedCSV = d3.csv.parseRows(data);
var container = d3.select("body")
.append("table")
.selectAll("tr")
.data(parsedCSV).enter()
.append("tr")
.selectAll("td")
.data(function(d) { return d; }).enter()
.append("td")
.text(function(d) { return d; });
});
</script>
There are some things I want you to add. If possible.
- Is it possible to use the tbody, thead and tfoot labels? /important!
- can we add an average line that can calculate automatically under each column?
- Can we add a simple chart under each column?
Thank you.
Content of the CSV:
car name,miles/gallon,cylinders,displacement,horsepower,weight,acceleration,model year,origin "chevrolet chevelle malibu",18,8,307,130,3504,12,70,1 "buick skylark 320",15,8,350,165,3693,11.5,70,1 "plymouth satellite",18,8,318,150,3436,11,70,1