Accepted answer

The line

.chart(function(c) { console.log(c);return dc.lineChart(c).dashStyle([2,3]).interpolate('cardinal').evadeDomainFilter(true); })

provides the function that generates subcharts. The parameters to this function appear to be undocumented, but a quick look at the source reveals

var subChart = _charts[sub.key] ||, _chart, chartGroup, sub.key, i);

that the function takes the following parameters:

  1. the composite chart
  2. the chart group where the composite chart is registered
  3. the key for the subchart
  4. the index for the subchart

It's that third argument that you want. It's the key returned by your seriesAccessor, and you can use whatever method you want to set the dashStyle based on that key.

Related Query