MCPcopy Create free account
hub / github.com/colbymchenry/codegraph / densify

Function densify

telemetry-dashboard/src/api.ts:126–128  ·  view source on GitHub ↗

Turns day-keyed rows into a dense series aligned to `labels`.

(labels: string[], byDay: Map<string, number>)

Source from the content-addressed store, hash-verified

124
125/** Turns day-keyed rows into a dense series aligned to `labels`. */
126function densify(labels: string[], byDay: Map<string, number>): number[] {
127 return labels.map((day) => byDay.get(day) ?? 0);
128}
129
130// ---------------------------------------------------------------------------
131// Dimensions

Callers 2

timeseriesFunction · 0.85
durationBucketSeriesFunction · 0.85

Calls 1

getMethod · 0.65

Tested by

no test coverage detected