* @param combiner A function that combines the results of the mapper.
* @param mapper A function to apply to each element.
* @return The result.
*/
public double aggregate(final BinaryFunction combiner, final UnaryFunction mapper) {
return aggregateRows(new VectorFunction() {
public double apply(Vector v) {
return v.aggregate(combiner, mapper);
}
}).aggregate(combiner, Functions.IDENTITY);
}