Created
March 17, 2018 08:28
-
-
Save adamjanes/4fd2027fce22d7cd0c0df0face9bba2c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Axes | |
var xAxisCall = d3.axisBottom(x) | |
var xAxis = g.append("g") | |
.attr("class", "x-axis") | |
.attr("transform", "translate(" + 0 + "," + height + ")") | |
.call(xAxisCall); | |
var yAxisCall = d3.axisLeft(y) | |
var yAxis = g.append("g") | |
.attr("class", "y-axis") | |
.call(yAxisCall) | |
// Labels | |
xAxis.append("text") | |
.attr("class", "axis-title") | |
.attr("transform", "translate(" + width + ", 0)") | |
.attr("y", -6) | |
.text("Grade Point Average") | |
yAxis.append("text") | |
.attr("class", "axis-title") | |
.attr("transform", "rotate(-90)") | |
.attr("y", 16) | |
.text("Height / Centimeters"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment