MCPcopy Create free account
hub / github.com/plotly/plotly.js / getRanges

Function getRanges

src/traces/histogram2d/calc.js:196–209  ·  view source on GitHub ↗
(edges, uniqueVals, gapLow, gapHigh, ax, calendar)

Source from the content-addressed store, hash-verified

194}
195
196function getRanges(edges, uniqueVals, gapLow, gapHigh, ax, calendar) {
197 var i;
198 var len = edges.length - 1;
199 var out = new Array(len);
200 var roundFn = getBinSpanLabelRound(gapLow, gapHigh, edges, ax, calendar);
201
202 for(i = 0; i < len; i++) {
203 var v = (uniqueVals || [])[i];
204 out[i] = v === undefined ?
205 [roundFn(edges[i]), roundFn(edges[i + 1], true)] :
206 [v, v];
207 }
208 return out;
209}

Callers 1

calc.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…