public static double[] selectByPredicate (double[] values, Boolean[] predicate) {
        return DMatrixUtils.selectByPredicate(values, ArrayUtils.toPrimitive(predicate));
    }
public static double [ ] selectByPredicate ( double [ ] values , Boolean [ ] predicate ) { return DMatrixUtils . selectByPredicate ( values , ArrayUtils . toPrimitive ( predicate ) ) ; }
Creates a new array by selecting those elements marked as true in the predicate array.

@param values The array where the elements are going to be selected from.
@param predicate The selection mapper.
@return The new array with selected items.