{
const svg = d3
.create("svg")
.attr("viewBox", [0, 0, width, height])
.attr("width", width)
.attr("height", height);
const baground = svg
.append("rect")
.attr("width", width)
.attr("height", height)
.attr("fill", "#AAAAAA");
for (let i = 0; i < blackMusicianData.length; i++) {
svg
.append("text")
.attr("x", width/2)
.attr("y", i*barHeight + margin)
.style("font-family", "Nunito")
.style("font-size", 10)
.style("text-anchor", "middle")
.style("alignment-baseline", "hanging")
.style("fill", "white")
.text(blackMusicianData[i].abbreviation.abbreviation);
svg
.append("rect")
.attr("width", widthScale(blackMusicianData[i].creatorCount))
.attr("height", barHeight)
.attr("x", width/2)
.attr("y", i*barHeight + margin)
.attr("fill", "none")
.attr("stroke-width", 3)
.attr("stroke", "#FF0000");
svg
.append("rect")
.attr("width", widthScale(blackDancerData[i].creatorCount))
.attr("height", barHeight)
.attr("x", width/2 - widthScale(blackDancerData[i].creatorCount))
.attr("y", i*barHeight + margin)
.attr("fill", "none")
.attr("stroke-width", 3)
.attr("stroke", "#FF0000");
}
return svg.node();
}