# Marginal Probability Function: Definition and Examples

< Probability and statistics definitions < Marginal probability function

## What is a marginal probability function?

The marginal probability function is performed by summing joint probabilities.

Suppose that two discrete random variables X, Y have a joint probability function p(x,y) = P[X = x, Y = y], Then

• pX(x) = P[X = x] is the marginal probability function of X and
• pY(y) = P[Y = y] is the marginal probability function of Y.

## Example: Marginal probability mass function (PMF)

The marginal probability mass function is defined as [1]

You can find the marginal probability mass function (PMF) of X by summing the joint probabilities using the above formula.

For example, suppose you had an urn of ten balls with four blue, three black and three red balls. The following joint probability mass function table shows the joint PMF for (X, Y) balls in an urn:

We can use the joint PMF table to find probabilities. For example, the probability that exactly three black balls are chosen — P(X = 3) — is found by summing values of the PMF where X = 3.

Using the formula, summing the probabilities, we get 3/252 + 12/252 + 6/252 = 21/252.

We can find the marginal PMF of X from Table 1 by repeating this process for each value of X. For example, row 0 is the sum of 6/252 and 12/252.

We can find also find the marginal PMF of Y from Table 1 in a similar way. Suppose we wanted to know P(Y = 3). We could sum the probabilities in table 1 over the rows in the column where Y = 3:

If we repeat this process for all columns, we get the marginal PMF of Y.

## Marginal probability function in Bayesian statistics

In Bayesian statistics, a marginal probability function is a multivariate probability function that gives the marginal probability for an event without a posteriori knowledge of other random variable’s events [2]. A posteriori refers to the probability of an event after taking into account all evidence.

## References

1. Chapter 6 Joint Probability Distributions. Retrieved August 6, 2023 from:  https://bayesball.github.io/BOOK/joint-probability-distributions.html
2. Melli, G. Marginal Probability Function. Retrieved August 6, 2023 from: http://www.gabormelli.com/RKB/Marginal_Probability_Function