D3.js dynamic graph