The following problems appeared as a project in the edX course ColumbiaX: CSMM.102x Machine Learning. The following problem description is taken from the course project itself.
The following figure shows a first few rows of a sample training dataset with d=2 dimensions and K=5 class labels.
x1 | x2 | y | |
---|---|---|---|
0 | 5.731453 | 4.517417 | 4 |
1 | -0.743516 | 2.157767 | 3 |
2 | 5.745734 | 1.205449 | 1 |
3 | -0.322106 | -0.183691 | 0 |
4 | 2.200057 | -1.658819 | 3 |
The following figure shows how the Bayesian Classifier can be first trained to estimate the Prior and the Class Conditional Gaussian Densities (as a Generative Model) and then using Bayes Rule the Posterior Probabilities for the class labels can be predicted on the new test dataset.
The following figures show the Gaussian class conditional densities learnt from the training dataset with MLE.
The following figure shows the predicted posterior probabilities on the test dataset.
The following figures show the decision boundaries learnt with the Bayesian Classsfier trained and tested on different sample datasets respectively.