or exprcond represents expr conditioned by the predicate cond.
- exprcond can be entered as expr cond cond or expr \[Conditioned] cond.
- The expression expr can correspond either to a predicate with logical values or to an object with numerical values.
- Probability[predcond,…] gives the conditional probability of pred given cond.
- Expectation[exprcond,…] gives the conditional expectation of expr given cond.
- Conditioned can be used in functions such as Probability, NProbability, Expectation, and NExpectation.
Examplesopen allclose all
Basic Examples (2)
Compute the probability of a conditional event:
Use NProbability to get the numerical value directly:
Compute a conditional expectation:
Use NExpectation to get the numerical value directly:
Compute a conditional expectation for a discrete distribution:
Use implicit time to compute a conditional probabiity for a random process:
Obtain the same result using the corresponding slice distribution:
Conditional probability for a multivariate slice of a random process using implicit times:
Obtain the same result using the corresponding multivariate slice distribution:
Properties & Relations (4)
A conditional probability is a ratio of two probabilities:
The conditional probability is 0 if the events are mutually exclusive:
Compute the probability of an event in a TruncatedDistribution:
Obtain the same result using a conditional probability calculation:
For independent variables, a conditional probability is the same as unconditional probability:
Wolfram Research (2010), Conditioned, Wolfram Language function, https://reference.wolfram.com/language/ref/Conditioned.html.
Wolfram Language. 2010. "Conditioned." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Conditioned.html.
Wolfram Language. (2010). Conditioned. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Conditioned.html