Shiny dashboard "Statistical foundations of machine learning"

Classification and assessment

Common left panel:

Univariate mixture

Goal: visualize the relation between posterior probability and class conditional density Univariate continuous input ${\bf x}$ and binary class taking two possible values: red and green. Both classes have a gaussian inverse conditional distribution $p({\bf x}=x| y)$

$p(x|{\bf y}=\text{red}) \sim {\mathcal N} (\mu_1, \sigma_1^2)$

$p(x|{\bf y}=\text{green}) \sim {\mathcal N} (\mu_2, \sigma_2^2)$

Top left sliders:

Top right: visualization of red and green class conditional densities together with the posterior probability function $P({\bf y}=\text{red}| x)$.

Suggested manipulation:

Linear discriminant

Goal: visualize the relation between bivariate class conditional densities and linear discriminant. Bivariate continuous input ${\bf x}$ and binary class taking two possible values: red and green. Both classes have a bivariate gaussian class conditional density $p({\bf x}=x| y)$

$p(x|{\bf y}=\text{red}) \sim {\mathcal N} ([\mu_{1x},\mu_{1y}]^T, \sigma_1^2 I_2)$

$p(x|{\bf y}=\text{green}) \sim {\mathcal N} ([\mu_{2x},\mu_{2y}]^T, \sigma_2^2 I_2)$ where $I_2$ is the diagonal [2,2] matrix.

Top left sliders:

Suggested manipulation:

Perceptron

Goal: visualize the iteration of the gradient based minimization of the hyperplane misclassification

Bivariate continuous input ${\bf x}$ and binary class taking two possible values: red and green. Both classes have a bivariate gaussian class conditional density $p({\bf x}=x| y)$

$p(x|{\bf y}=\text{red}) \sim {\mathcal N} ([\mu_{1x},\mu_{1y}]^T, \sigma_1^2 I_2)$

$p(x|{\bf y}=\text{green}) \sim {\mathcal N} ([\mu_{2x},\mu_{2y}]^T, \sigma_2^2 I_2)$ where $I_2$ is the diagonal [2,2] matrix.

Top left sliders:

Suggested manipulation:

Assessment

Goal: visualize the relation between ROC curve, PR curve, confusion matrix and classifier threshold. Univariate continuous input ${\bf x}$ and binary class taking two possible values: red (-) and green (+). Both classes have a gaussian inverse conditional distribution $p({\bf x}=x| y)$

$p(x|{\bf y}=\text{red})= p(x|{\bf y}=\text{(-)}) \sim {\mathcal N} (\mu_{(-)}, \sigma_{(-)}^2)$

$p(x|{\bf y}=\text{green})= p(x|{\bf y}=\text{(+)}) \sim {\mathcal N} (\mu_{(+)}, \sigma_{(+)}^2)$

Top left sliders:

center left: visualization of threshold and data distribution. The color of the dashed areas identify the classes returned by the classifier

center right: visualization of ROC curve: red dot is the ROC point associated to the threshold. Title contains the TPR, FPR associated to the threshold and the Area under the ROC curve.

bottom left: confusion matrix associated to the threshold together with assessment statistics (TPR, TNT, and so on)

bottom right: visualization of PR curve: red dot is the PR point associated to the threshold

Suggested manipulation:



gbonte/gbcode documentation built on Feb. 27, 2024, 7:38 a.m.