activity = Plot.plot({
color: {
type: "threshold",
scheme: "orrd",
domain: [0.25, 0.5, 0.75, 0.95, 0.99].map((d) =>
Math.round(d3.quantile(value, d))
)
},
projection: { type: () => projection, domain: { type: "Sphere" } },
marks: [
Plot.geo(land, {
clip: "sphere",
fill: "#555",
strokeWidth: 0.5
}),
Plot.graticule({ clip: "sphere" }),
Plot.dot(
dataRdn,
Plot.hexbin(
{
fill: (g) => d3["max"](g, (d) => d.activity),
title: (elems) =>
`${rdn} (max.): ${parseInt(d3["max"](elems, (d) => d.activity))}`
},
{
x: "lon",
y: "lat",
fillOpacity: 0.9,
symbol: "hexagon",
stroke: "black",
strokeWidth: 0.1,
binWidth: 5
}
)
),
Plot.sphere({ strokeWidth: 0.5 })
],
caption: htl.html`MARIS Sediments ${rdn} activity (hover on hexagon to see the maximum value).`,
width: 1200
})