Plot.plot({
marginLeft: 200,
width: 1200,
height: 800,
x: {
},
marks: [
Plot.barX(totalBar, {
x: "count",
y: "infrastructure_type_id",
sort: { y: "x", reverse: true },
fill: (d) =>
d.infrastructure_type_id == "5G relationship" ? "#DC6641" : "#4A4A4A"
}),
Plot.barX(filterBarData, {
x: "count",
y: "infrastructure_type_id",
sort: { y: "x", reverse: true },
fill: (d) =>
d.infrastructure_type_id == "5G relationship" ? "#DC6641" : "#747474",
insetTop: 5,
insetBottom: 5
}),
Plot.text(totalBar, {
x: "count",
y: "infrastructure_type_id",
text: "count",
fontWeight: "bold",
fontSize: 10,
dx: 12
}),
Plot.text(filterBarData, {
x: "count",
y: "infrastructure_type_id",
text: "count",
fill: "white",
fontWeight: "bold",
fontSize: 12,
dx: 12
}),
Plot.axisY({
ticks: 0,
tickSize: 0
}),
Plot.axisX({
ticks: 0,
tickSize: 0
})
]
})