d3.select('#chart') .append('svg') .attr('width', 600) .attr('height', 400) .style('background', "red") .append('rect') .attr('x', 200) .attr('y', 100) .attr('height', 200) .attr('width', 200) .style('fill', 'green') d3.select('svg') .append('circle') .attr('cx', 60) .attr('cy', 300) .attr('r', 50) .style('fill','yellow')