plot_gdp_cop = Plot.plot({
title: "Annual GDP & C02 Emissions by Country",
caption: "Data Source: World Bank",
x: {grid: true, type: "log"},
y: {grid: true, type: "log"},
marks: [
Plot.dot(world_bank_data, {
filter: (d) => (d.year === 2019),
x: "gdp",
y: "co2",
fill: "black",
tip: true
}),
Plot.linearRegressionY(world_bank_data, {
filter: (d) => (d.year === 2019),
x: "gdp",
y: "co2",
fill: "red",
stroke: "red"
})
]
})