Skip to content

Commit

Permalink
Fix lda.jl docstrings (#226)
Browse files Browse the repository at this point in the history
  • Loading branch information
abhro committed Apr 1, 2024
1 parent 285cac7 commit cade202
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/lda.jl
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,8 @@ Return the linear discriminant model coefficient vector.
weights(f::LinearDiscriminant) = f.w

"""
length(f::LinearDiscriminant)
Get the length of the coefficient vector.
"""
length(f::LinearDiscriminant) = length(f.w)
Expand Down Expand Up @@ -264,15 +266,15 @@ the weight equals the number of samples of each class.
"""
classweights(M::MulticlassLDA) = classweights(M.stats)
"""
withinclass_scatter(M)
withinclass_scatter(M)
Get the within-class scatter matrix (of size ``(d, d)``).
Get the within-class scatter matrix (of size ``(d, d)``).
"""
withclass_scatter(M::MulticlassLDA) = withclass_scatter(M.stats)
"""
betweenclass_scatter(M)
betweenclass_scatter(M)
Get the between-class scatter matrix (of size ``(d, d)``).
Get the between-class scatter matrix (of size ``(d, d)``).
"""
betweenclass_scatter(M::MulticlassLDA) = betweenclass_scatter(M.stats)

Expand Down

0 comments on commit cade202

Please sign in to comment.