Skip to content

Function to compute matmul(transpose(A),A)? #375

Open
@Beliavsky

Description

@Beliavsky

Stdlib has corr and cov functions that compute the correlation and covariance matrices of the columns of an array. Computing the correlation matrix of the columns of array A, assuming that the elements of each column have been shifted by the column mean, involves calculating

matmul(transpose(A),A)

Could this be added as a function? If this can be computed efficiently, the programmer can calculate the correlation matrix using computed or a priori means and variances, as I described in Give stats functions optional mean arguments?

BLAS does have dgemm to multiply matrices, either of which may be transposed, but does it optimize the special but common case that the two matrices are the same?

Metadata

Metadata

Assignees

No one assigned

    Labels

    topic: mathematicslinear algebra, sparse matrices, special functions, FFT, random numbers, statistics, ...

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions