commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Phil Steitz (JIRA)" <>
Subject [jira] [Commented] (MATH-894) Spurious method call in "ResizableDoubleArray" ("o.a.c.m.util")
Date Mon, 12 Nov 2012 22:27:16 GMT


Phil Steitz commented on MATH-894:

I agree that getInternalValues should be deprecated; but its use in DescriptiveStatistics
needs to be replaced.  One idea on how to do this, per discussion on the mailing list, is
to add
public double applyStatistic(UnivariateStatistic stat) {
    return stat.evaluate(internalArray, startIndex, numElements);

Then in DescriptiveStatistics, apply becomes

public double apply(UnivariateStatistic stat) {
        return eDA.applyStatistic(stat);

+1 to deprecate the pre-enum flags and replace with an enum.

> Spurious method call in "ResizableDoubleArray" ("o.a.c.m.util")
> ---------------------------------------------------------------
>                 Key: MATH-894
>                 URL:
>             Project: Commons Math
>          Issue Type: Improvement
>    Affects Versions: 3.0
>            Reporter: Gilles
>            Assignee: Gilles
>            Priority: Minor
>             Fix For: 3.1
> Method "addElement" should not call "contract()", as it will almost always make the storage
array shrink on the first call since it will be considered "too big" (for just storing one
> See discussion about this change in MATH-757.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

View raw message