feat: add sample size
This commit is contained in:
parent
de79970987
commit
9d65c1d1df
@ -214,7 +214,12 @@ def mvp():
|
||||
for i, p in enumerate(r.mvps):
|
||||
ranks[p] = ranks.get(p, []) + [i + 1]
|
||||
return [
|
||||
{"name": p, "rank": f"{np.mean(v):.02f}", "std": f"{np.std(v):.02f}"}
|
||||
{
|
||||
"name": p,
|
||||
"rank": f"{np.mean(v):.02f}",
|
||||
"std": f"{np.std(v):.02f}",
|
||||
"n": len(v),
|
||||
}
|
||||
for p, v in ranks.items()
|
||||
]
|
||||
|
||||
|
@ -83,8 +83,9 @@ const RaceChart: FC<RaceChartProps> = ({ players, std }) => {
|
||||
fontWeight={"bold"}
|
||||
strokeWidth={4}
|
||||
paintOrder={"stroke fill"}
|
||||
style={{ whiteSpace: "pre" }}
|
||||
>
|
||||
{`${player.rank} ± ${player.std}`}
|
||||
{`${player.rank} ± ${player.std} N = ${player.n}`}
|
||||
</text>
|
||||
</g>
|
||||
))}
|
||||
|
@ -2,7 +2,7 @@ export interface Edge {
|
||||
from: string;
|
||||
to: string;
|
||||
color: string;
|
||||
relation: "likes" | "dislikes"
|
||||
relation: "likes" | "dislikes";
|
||||
}
|
||||
export interface Node {
|
||||
id: string;
|
||||
@ -16,5 +16,5 @@ export interface PlayerRanking {
|
||||
name: string;
|
||||
rank: number;
|
||||
std: number;
|
||||
n: number;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user