# Bayes Theorem (ML Algorithm)

### Introduction

• Bayes theorem is one of ML algorithm.
• Machine learning algorithms are mainly used to make predictions (predictive modelling) or Classification.
• We can use Probability to form  predictions in machine learning.
• The problem of classification is often written as calculating the contingent probability of a category label given a knowledge sample.
• Machine learning algorithms handle the large set of random data and predict the outcome.
• To handle the large random data (Big data), the probability is used.
• In machine learning, we have an interest to work out the simplest hypothesis “h” from some space.
• H, given the observed training data D.
• Best hypothesis mean, most probable hypothesis.
• Bayes Theorem provides a principled way of calculating this conditional probability.

### Features of Bayesian Learning Methods

Bayes theorem (ML Algorithm) has Each training example, can incrementally decrease or increase the estimated probability, so
That’s a hypothesis is correct.

This provides a flexible approach to learning, because some algorithms completely
eliminate a hypothesis if it is inconsistent with any single example

Prior knowledge can be combined with observed data to determine the final probability of a
Hypothesis. In Bayesian learning, 2 components of prior knowledge are

1. A prior probability of each candidate hypothesis, and
2. A probability distribution observed data for each possible hypothesis.
Bayesian methods can accommodate hypotheses that make probabilistic predictions
New instances can be classified by combining the predictions of multiple hypotheses,
Weighted by their probabilities.
In some cases, even though Bayesian methods become computationally complex, but still,
they provide an optimal decision-making solutions, compared to other practical methods.

### Bayes Theorem

• In machine learning, we are interested to determine the best hypothesis “h” from some space H, given the observed training data D.
• In Bayesian learning, best hypothesis mean: Most probable hypothesis, given the data D
• plus some initial knowledge about the prior probabilities of the various hypotheses in H.
• Bayes theorem provides a way to calculate the probability of a hypothesis based on its prior probability, the probabilities of observing various data given the hypothesis, and the observed data itself.