Skip to content

Commit

Permalink
DOC add missing class priors in LDA equation (#10340)
Browse files Browse the repository at this point in the history
  • Loading branch information
lzlarryli authored and lesteve committed Dec 19, 2017
1 parent 7b54351 commit 3929eea
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion doc/modules/lda_qda.rst
Expand Up @@ -87,7 +87,12 @@ linear decision surfaces between, as can be seen by comparing the
log-probability ratios :math:`\log[P(y=k | X) / P(y=l | X)]`:

.. math::
\log\left(\frac{P(y=k|X)}{P(y=l | X)}\right) = 0 \Leftrightarrow (\mu_k-\mu_l)\Sigma^{-1} X = \frac{1}{2} (\mu_k^t \Sigma^{-1} \mu_k - \mu_l^t \Sigma^{-1} \mu_l)
\log\left(\frac{P(y=k|X)}{P(y=l|X)}\right)=
\log\left(\frac{P(X|y=k)P(y=k)}{P(X|y=l)P(y=l)}\right)=0 \Leftrightarrow
(\mu_k-\mu_l)^t\Sigma^{-1} X =
\frac{1}{2} (\mu_k^t \Sigma^{-1} \mu_k - \mu_l^t \Sigma^{-1} \mu_l)
- \log\frac{P(y=k)}{P(y=l)}
In the case of QDA, there are no assumptions on the covariance matrices
:math:`\Sigma_k` of the Gaussians, leading to quadratic decision surfaces. See
Expand Down

0 comments on commit 3929eea

Please sign in to comment.