MCPcopy Create free account
hub / github.com/cortex-js/compute-engine / shapeError

Function shapeError

src/compute-engine/library/statistics.ts:857–862  ·  view source on GitHub ↗
(ce: ComputeEngine, name: string)

Source from the content-addressed store, hash-verified

855 const nonReal = nonRealUnivariateError(engine, 'Quartiles', xs);
856 if (nonReal) return nonReal;
857 // A datum with no real value leaves the sort with nothing to order by
858 // (`hasValuelessDatum`), so all three quartiles are unknown — the same
859 // triple an absent datum produces.
860 if (hasValuelessDatum(xs))
861 return engine.tuple(engine.NaN, engine.NaN, engine.NaN);
862 if (!numericApproximation) {
863 const vals = exactData(xs);
864 if (vals) {
865 const [q1, q2, q3] = exactQuartiles(engine, vals);

Callers 2

evaluateCovarianceFunction · 0.85
evaluateCorrelationFunction · 0.85

Calls 1

errorMethod · 0.65

Tested by

no test coverage detected