Created
March 26, 2016 14:16
-
-
Save cannelflow/478328a4cb21afc4de44 to your computer and use it in GitHub Desktop.
demo.js
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
tried like | |
//update data | |
rects.attr({ | |
"x": function (d) { return xScale(d.country); }, | |
"y": function (d) { return yScale(d.gdp); }, | |
"width": xScale.rangeBand(), | |
}). | |
attr("height", 0). | |
attr("y", h). | |
transition().duration(3000). | |
delay(function (d, i) { | |
return i * 200; | |
}). | |
attr("height", function (d) { | |
return h - yScale(d.gdp) | |
}); | |
its working but bar is going downward with transition |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment