Control Panel
Data Loading
Dataset will be loaded from cache if available, otherwise downloaded from Kaggle
Training
Test Email
Probability Distributions
Bayes' Theorem Step-by-Step Breakdown
Bayes' Theorem Formula
Prior Probabilities P(Class)
PendingThe prior probability represents our initial belief about the class distribution based on the training data.
Likelihood P(Features|Class)
PendingThe likelihood measures how probable the observed features are, given each class. We calculate this for each feature using Gaussian distributions.
Combining: Prior × Likelihood
PendingWe multiply the prior probabilities by the likelihoods to get unnormalized posterior probabilities.
Normalization: Posterior Probabilities
PendingWe normalize by dividing by P(Features), which is the sum of all unnormalized posteriors, ensuring probabilities sum to 1.
Final Prediction
PendingThe class with the highest posterior probability is selected as the prediction.