Function: logoDot()
logoDot(
o):DotRenderer
Defined in: packages/sdvplot/src/recharts.ts:218
Team logos as a series' points: the dot of a <Line> / <Area>, or the shape of a <Scatter>. Each point
draws the logo of its data row's team column, size px tall and centred on the point; last: true draws only
the series' final point (an end-dot). A team with no logo draws nothing and warns once, as sdvplot/echarts does.
Parameters
o
Returns
Example
import { loadLeague } from "@sportsdataverse/sdvplot";
import { logoDot } from "@sportsdataverse/sdvplot/recharts";
import { Scatter, ScatterChart, XAxis, YAxis } from "recharts";
await loadLeague("nfl");
const rows = [
{ team: "KC", pf: 385, pa: 326 },
{ team: "LAC", pf: 402, pa: 301 },
];
<ScatterChart width={400} height={300}>
<XAxis dataKey="pf" type="number" domain={[350, 450]} />
<YAxis dataKey="pa" type="number" domain={[280, 350]} />
<Scatter data={rows} shape={logoDot({ team: "team", league: "nfl", size: 32 })} />
</ScatterChart>;