mirror of
https://github.com/ankitects/anki.git
synced 2026-01-10 12:33:55 -05:00
corrections from ninja check
This commit is contained in:
parent
8ab9e54a62
commit
ce9b087190
1 changed files with 1 additions and 2 deletions
|
|
@ -134,12 +134,11 @@ export function renderReviews(
|
||||||
|
|
||||||
const sourceMap = showTime ? sourceData.reviewTime : sourceData.reviewCount;
|
const sourceMap = showTime ? sourceData.reviewTime : sourceData.reviewCount;
|
||||||
// Create bins using the thresholds: each bin contains data points between consecutive thresholds
|
// Create bins using the thresholds: each bin contains data points between consecutive thresholds
|
||||||
let bins = bin()
|
const bins = bin()
|
||||||
.value((m) => m[0]) // Extract the day number from each map entry [day, data]
|
.value((m) => m[0]) // Extract the day number from each map entry [day, data]
|
||||||
.domain(x.domain() as any) // Bins are constrained to this domain [xMin, xMax]
|
.domain(x.domain() as any) // Bins are constrained to this domain [xMin, xMax]
|
||||||
.thresholds(thresholds)(sourceMap.entries() as any); // Use computed thresholds to split data into bins
|
.thresholds(thresholds)(sourceMap.entries() as any); // Use computed thresholds to split data into bins
|
||||||
|
|
||||||
|
|
||||||
// empty graph?
|
// empty graph?
|
||||||
const totalDays = sum(bins, (bin) => bin.length);
|
const totalDays = sum(bins, (bin) => bin.length);
|
||||||
if (!totalDays) {
|
if (!totalDays) {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue