We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 109a142 commit 6ae03d8Copy full SHA for 6ae03d8
1 file changed
src/diagnostics.jl
@@ -45,6 +45,7 @@ Computational Statistics & Data Analysis 43.4 (2003): 541-552.
45
function euclideanDistances(dataMatrix::AbstractMatrix{Float64})::AbstractMatrix{Float64}
46
n = size(dataMatrix, 1)
47
d = Array{Float64, 2}(undef, n, n)
48
+ fill!(d, 0.0)
49
for i ∈ 1:n
50
for j ∈ i:n
51
if i != j
@@ -60,7 +61,7 @@ end
60
61
62
function mahalanobisSquaredBetweenPairs(pairs::AbstractMatrix{Float64}; covmatrix = nothing)::Union{Nothing, AbstractMatrix}
63
n = size(pairs, 1)
- newmat = Array{Float64, 2}(undef, n, n)
64
+ newmat = zeros(n, n)
65
if isnothing(covmatrix)
66
covmatrix = cov(pairs)
67
end
0 commit comments