MCPcopy Create free account
hub / github.com/javascriptdata/danfojs / applyFunc

Function applyFunc

src/danfojs-node/test/core/series.test.ts:895–897  ·  view source on GitHub ↗
(x: any)

Source from the content-addressed store, hash-verified

893 it("apply a function to a series element", function () {
894 const sf = new Series([1, 2, 3, 4, 5, 6, 7, 8]);
895 const applyFunc = (x: any) => {
896 return x + x;
897 };
898
899 const rslt = [2, 4, 6, 8, 10, 12, 14, 16];
900 assert.deepEqual((sf.apply(applyFunc)).values, rslt);

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected