Chain rule (probability): Difference between revisions
m Corrected poor notation. |
|||
Line 35: | Line 35: | ||
For two random variables <math>X,Y</math>, to find the joint distribution, we can apply the definition of conditional probability to obtain: |
For two random variables <math>X,Y</math>, to find the joint distribution, we can apply the definition of conditional probability to obtain: |
||
<math display=block>\mathrm P(X,Y) = \mathrm P(X \mid Y) \cdot \mathrm P(Y) |
<math display=block>\mathrm P(X = x,Y = y) = \mathrm P(X = x\mid Y = y) \cdot \mathrm P(Y = y)</math> |
||
for any possible values <math>x</math> of <math>X</math> and <math>y</math> of <math>Y</math> in the discrete case or, in general, |
|||
<math display=block>\mathrm P(X \in A,Y \in B) = \mathrm P(X \in A\mid Y \in B) \cdot \mathrm P(Y \in B)</math> |
|||
for any possible measurable sets <math>A</math> and <math>B</math>. |
|||
If one desires a notation for the probability distribution of <math>X</math>, one can use <math>P_X</math>, so that <math>P_X(x) := P(X = x)</math> in the discrete case or, in general, <math>P_X(A) := P(X \in A)</math> for a measurable set <math>A</math>. |
|||
'''Note: in the examples below, it is meaningless to write <math>P(X)</math> for a single random variable <math>X</math> or multiple random variables. We have left them as an earlier editor wrote them to provide an example to warn against this incomplete notation. It is particularly egregious to write intersections of random variables.''' |
|||
===More than two random variables=== |
===More than two random variables=== |
Revision as of 01:14, 4 November 2022
In probability theory, the chain rule (also called the general product rule[1][2]) permits the calculation of any member of the joint distribution of a set of random variables using only conditional probabilities. The rule is useful in the study of Bayesian networks, which describe a probability distribution in terms of conditional probabilities.
Chain rule for events
Two events
The chain rule for two random events and says
Example
This rule is illustrated in the following example. Urn 1 has 1 black ball and 2 white balls and Urn 2 has 1 black ball and 3 white balls. Suppose we pick an urn at random and then select a ball from that urn. Let event be choosing the first urn: Let event be the chance we choose a white ball. The chance of choosing a white ball, given that we have chosen the first urn, is Event would be their intersection: choosing the first urn and a white ball from it. The probability can be found by the chain rule for probability:
More than two events
For more than two events the chain rule extends to the formula which by induction may be turned into
Example
With four events (), the chain rule is
Chain rule for random variables
Two random variables
For two random variables , to find the joint distribution, we can apply the definition of conditional probability to obtain: for any possible values of and of in the discrete case or, in general, for any possible measurable sets and .
If one desires a notation for the probability distribution of , one can use , so that in the discrete case or, in general, for a measurable set .
Note: in the examples below, it is meaningless to write for a single random variable or multiple random variables. We have left them as an earlier editor wrote them to provide an example to warn against this incomplete notation. It is particularly egregious to write intersections of random variables.
More than two random variables
Consider an indexed collection of random variables . To find the value of this member of the joint distribution, we can apply the definition of conditional probability to obtain: Repeating this process with each final term creates the product:
Example
With four variables (), the chain rule produces this product of conditional probabilities:
See also
- Independence (probability theory) – When the occurrence of one event does not affect the likelihood of another
References
- ^ Schum, David A. (1994). The Evidential Foundations of Probabilistic Reasoning. Northwestern University Press. p. 49. ISBN 978-0-8101-1821-8.
- ^ Klugh, Henry E. (2013). Statistics: The Essentials for Research (3rd ed.). Psychology Press. p. 149. ISBN 978-1-134-92862-0.
- Russell, Stuart J.; Norvig, Peter (2003), Artificial Intelligence: A Modern Approach (2nd ed.), Upper Saddle River, New Jersey: Prentice Hall, ISBN 0-13-790395-2, p. 496.
- "The Chain Rule of Probability", developerWorks, Nov 3, 2012.