Consider the following code:
var svg = d3.select(\'#somediv\').append(\"svg\").attr(\"width\", w).attr(\"height\", h);
I would like to refa
To save a little bit of time you can use d3.ns.prefix.svg
var svg = document.createElementNS(d3.ns.prefix.svg, 'svg');