已知两个正态分布的随机变量,可以用那个函数求解他们的相关系数矩阵。
julia> using Statistics
help?> cor
search: cor Core VecOrMat Vector factorial DenseVecOrMat Cshort BitVector StridedVecOrMat isconcretetype convert DenseVector QuickSort Cushort searchsorted
cor(x::AbstractVector)
Return the number one.
─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
cor(X::AbstractMatrix; dims::Int=1)
Compute the Pearson correlation matrix of the matrix X along the dimension dims.
─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
cor(x::AbstractVector, y::AbstractVector)
Compute the Pearson correlation between the vectors x and y.
─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
cor(X::AbstractVecOrMat, Y::AbstractVecOrMat; dims=1)
Compute the Pearson correlation between the vectors or matrices X and Y along the dimension dims.
谢谢你的回复,对我很有帮助。