MCPcopy
hub / github.com/josdejong/mathjs / callback

Function callback

test/unit-tests/function/matrix/map.test.js:22–22  ·  view source on GitHub ↗
(valueA, valueB)

Source from the content-addressed store, hash-verified

20 const arrA = [[1, 2, 3], [4, 5, 6]]
21 const arrB = [[10, 20, 30], [40, 50, 60]]
22 const callback = function (valueA, valueB) { return valueA * 2 + valueB }
23 const arr2 = math.map(arrA, arrB, callback)
24 const expected = [[12, 24, 36], [48, 60, 72]]
25 assert.deepStrictEqual(arr2, expected)

Callers 3

timesFunction · 0.50
timesFunction · 0.50
timesFunction · 0.50

Calls 1

getMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…