main = {
const {margin, innerHeight, innerWidth} = config;
const {xScale, yScale, cScale} = scales;
const {xAxis, yAxis} = axises;
const {series} = format;
// main svg group
const main = d3.select(svg).append('g')
.attr('class', 'main')
.attr('transform', `translate(${margin.left}, ${margin.top})`);
// x axis
main.append('g')
.attr('class', 'axis x')
.attr('transform', `translate(0, ${innerHeight})`)
.call(xAxis);
// x axis label
d3.select('g.axis.x')
.append('text')
.attr('class', 'label')
.attr('x', innerWidth / 2)
.attr('y', 35)
.text('Year')
.style('text-anchor', 'middle');
// y axis
main.append('g')
.attr('class', 'axis y')
.call(yAxis);
// y axis label
d3.select('.y.axis').append('text')
.attr('class', 'label')
.attr('x', -innerHeight / 2 + 25)
.attr('y', -50)
.attr('transform', `rotate(-90 0 0)`)
.text('Ethnicity')
.style('text-anchor', 'middle');
return main;
}