Jack Daniel's Jack Daniel's - 18 days ago 5
Javascript Question

Render only specific chart using dc.js

How can I render only specific chart not all using dc.js.

renderAll() function accepts group. However, what is group in this context is not clear. Following doesnt work,

var priceChart = dc.rowChart("#price-chart");
dc.renderAll(priceChart)

Answer

What you want to write instead is :

var priceChart = dc.rowChart("#price-chart","mygroup");
dc.renderAll("mygroup");