score:7

Accepted answer

You need to select the 'rect' element. Try this:

var rect = d3.select("#test rect");

rect.transition().duration(5000).attr('height',200);

If you want to update multiple elements, use d3.selectAll().


More Query from same tag