MCPcopy Create free account
hub / github.com/EdwardRaff/JSAT / applyFunction

Method applyFunction

JSAT/src/jsat/linear/Vec.java:700–704  ·  view source on GitHub ↗

Applies the given function to each and every value in the vector. This method should be overloaded for a serious implementation. @param f the single variable function to apply

(Function f)

Source from the content-addressed store, hash-verified

698 * @param f the single variable function to apply
699 */
700 public void applyFunction(Function f)
701 {
702 for(int i = 0; i < length(); i++)
703 set(i, f.f(get(i)));
704 }
705
706 /**
707 * Applies the given function to each and every value in the vector.

Callers 4

trainCMethod · 0.95
feedForwardMethod · 0.95
testApplyFunctionMethod · 0.45
trainMethod · 0.45

Calls 4

lengthMethod · 0.95
setMethod · 0.95
getMethod · 0.95
fMethod · 0.65

Tested by 1

testApplyFunctionMethod · 0.36