[ 
https://issues.apache.org/jira/browse/MATH-978?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13663123#comment-13663123
 ] 

Ajo Fod commented on MATH-978:
------------------------------

Code to be added to StorelessCovariance: 

    public void append(StorelessCovariance sc) throws 
DimensionMismatchException{
        if (sc.dimension != dimension) {
            throw new DimensionMismatchException(sc.dimension, dimension);
        }

        // only update the upper triangular part of the covariance matrix
        // as only these parts are actually stored
        for (int i = 0; i < dimension; i++){
            for (int j = i; j < dimension; j++){
                getElement(i, j).append(sc.getElement(i, j));
            }
        }        
    }

                
> StorelessCovariance to be map/reducable
> ---------------------------------------
>
>                 Key: MATH-978
>                 URL: https://issues.apache.org/jira/browse/MATH-978
>             Project: Commons Math
>          Issue Type: New Feature
>            Reporter: Ajo Fod
>   Original Estimate: 2h
>  Remaining Estimate: 2h
>
> Current version of StorelessCovariance and StorelessBivariateCovariance don't 
> allow adding another StorelessCovariance to an existing one. With this 
> feature it is possible to run maps on different data sets and then do a final 
> reduce to get the overall covariance.

--
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: http://www.atlassian.com/software/jira

Reply via email to