reduce


function reduce<Type, Lambda>(iter:Iterator<Type>, init:Type, op:Lambda) -> Type

Reduction.

  • iter Iterator.
  • init Initial value.
  • op Operator.

function reduce<Type, Output, Lambda>(x:Type[_], init:Output, op:Lambda) -> Output

Reduction.

  • x Vector.
  • init Initial value.
  • op Operator.

function reduce<Type, Output, Lambda>(X:Type[_,_], init:Output, op:Lambda) -> Output

Reduction.

  • X Matrix.
  • init Initial value.
  • op Operator.