MCPcopy Create free account
hub / github.com/idank/explainshell / d3_time_scaleUTCGetYear

Function d3_time_scaleUTCGetYear

explainshell/web/static/js/d3.v3.js:8401–8404  ·  view source on GitHub ↗
(d)

Source from the content-addressed store, hash-verified

8399 return d;
8400 }
8401 function d3_time_scaleUTCGetYear(d) {
8402 var y = d.getUTCFullYear(), d0 = d3_time_scaleUTCSetYear(y), d1 = d3_time_scaleUTCSetYear(y + 1);
8403 return y + (d - d0) / (d1 - d0);
8404 }
8405 d3_time_scaleUTCMethods.year = function(extent, m) {
8406 return d3_time_scaleLinear.domain(extent.map(d3_time_scaleUTCGetYear)).ticks(m).map(d3_time_scaleUTCSetYear);
8407 };

Callers

nothing calls this directly

Calls 1

d3_time_scaleUTCSetYearFunction · 0.85

Tested by

no test coverage detected