Concepts / Probability Distributions

Probability Distributions

D is the distribution; z ∼ D describes sampling from it.

  • Programming

From Distribution to Sample

Probability notation becomes easier to read when you begin with D. The symbol D names a distribution over a set. It describes how values are selected from that set. The expression z ∼ D then connects a particular variable, z, with that distribution: z is sampled according to D.

The symbol z does not identify one permanently fixed value. It represents a value obtained through the sampling process described by D. Once this relationship is established, later expressions can use z to evaluate a function, an event, or an expected value.

Ddistribution over Zz₁probability assigned by Dz₂probability assigned by Dz₃probability assigned by Dassigns probabilityassigns probabilityassigns probability
How does D describe the possible values from which z may be sampled?

Reading the Sampling Statement

Read z ∼ D as: z is sampled according to D. Start at D, which identifies the distribution. Then read z as the variable receiving a value from that distribution. The statement describes a sampling relationship, not a permanent assignment to one fixed value.

In the real world

Generated example: Suppose D describes how a value is selected from a set of colors. Writing z ∼ D means that z is treated as the color produced by a draw governed by D. The notation does not say that z must always be one particular color; it establishes how z is obtained.

Dsampling rulesampleaccording to Dzsampled valuegovernsproduces
How does a distribution produce a sampled value z?

Functions and Events

After z ∼ D has established the sampling context, the notation inside brackets determines what is being summarized. Expected-value notation summarizes a real-valued function of the sampled variable. The expression E with subscript z ∼ D followed by f(z) denotes the expected value of f(z) when z is sampled according to D.

Probability notation instead asks how often a condition is true. If f maps Z to true or false, then P with subscript z ∼ D followed by f(z) denotes the probability that f(z) is true when z is sampled according to D. In set language, this is the probability assigned by D to the values for which the condition is true.

Notation typeWhat it summarizesQuestion it answers
Expected valueA real-valued function of a sampled variableWhat expected quantity is associated with f(z) under D?
Probability of an eventWhether a Boolean condition is trueHow likely is f(z) to be true under D?

Both expressions use the same sampling context, but they summarize different kinds of information.

Worked example

Separating a Quantity from a Condition

Let z be sampled according to D. Compare an expression that uses f(z) as a real-valued quantity with one that uses f(z) as a true-or-false condition.

  1. 1
    Identify the sampled variable

    The phrase z ∼ D says that z is sampled according to D.

  2. 2
    Read the expected-value expression

    An expected value summarizes the real-valued function f(z) over samples governed by D.

  3. 3
    Read the probability expression

    A probability expression summarizes whether the condition f(z) is true over samples governed by D.

Result

Expected-value notation summarizes a value produced by a function, while probability notation summarizes the truth of an event.

Expected valuesummarizes f(z)real-valued functionof sampled zEvent probabilitysummarizes f(z) trueBoolean conditiontrue or falsesummarizessummarizes
What is the difference between averaging a quantity and measuring how often a condition is true?

Independent Tuples

D describes individual samples from Z. When m points are sampled from D, the result is an m-component tuple written as (z₁, …, zₘ). The notation Dm refers to the probability over Zm induced by this process, where each zᵢ is sampled from D independently of the other points.

The superscript m does not describe one individual sample raised to a numerical power. It signals a distribution over a larger space: the space of m-component sample tuples. The important change is the object being described. D governs individual values, while Dm governs complete tuples produced by repeated independent sampling.

Ddistribution over Zz₁sample from D(z₁, …, zₘ)one outcome in Z^m z₂sample from Dzₘsample from Dindependent drawindependent drawindependent drawcomponentcomponentcomponent
What does Dm contain when m points are sampled independently from D?
In the real world

Generated example: If m points are sampled from D, one outcome is a tuple such as (z₁, …, zₘ). Dm describes the probability over all such m-component tuples, rather than describing only z₁ or only another single component.

Notation Mistakes

  • Common mistake

    Treating z ∼ D as if it assigned one permanently fixed value to z.

    What it looks like

    Reading the statement as saying that z is always one particular member of Z.

    Why it fails

    The notation describes z as a value obtained by sampling from D.

    Do this instead

    Read it as: z is sampled according to D.

  • Common mistake

    Confusing an expected value with an event probability.

    What it looks like

    Treating E with subscript z ∼ D followed by f(z) and P with subscript z ∼ D followed by f(z) as interchangeable.

    Why it fails

    Expected-value notation summarizes a real-valued function, while probability notation summarizes whether a Boolean condition is true.

    Do this instead

    First ask whether the expression summarizes a quantity or the truth of an event.

  • Common mistake

    Reading Dm as one individual sample raised to a power.

    What it looks like

    Interpreting D^m as a modified version of one value sampled from D.

    Why it fails

    Dm is the induced probability over m-component tuples in Zm.

    Do this instead

    Read the superscript as indicating repeated independent sampling and a tuple-valued outcome.

  • Common mistake

    Ignoring the distribution subscript when reading an expectation or probability.

    What it looks like

    Treating the subscript z ∼ D as decorative notation.

    Why it fails

    The subscript identifies the distribution governing the variable inside the brackets.

    Do this instead

    Use the subscript to identify which sampling process the expression summarizes.

Check Your Reading

MEDIUM

For each statement, identify what is being described: an individual sampled value, an expected quantity, an event probability, or a distribution over tuples. Then explain the role of D or Dm.

Hints
  • Begin with D: it names the distribution over the underlying set.
  • For z ∼ D, focus on how z is obtained.
  • For an expected value, look for a real-valued function.
  • For an event probability, look for a Boolean condition.
  • For Dm, look for m independently sampled components forming a tuple.

Key Takeaways

  1. 1
    D names a probability distribution over a set.
  2. 2
    z ∼ D means that z is sampled according to D.
  3. 3
    Expected-value notation summarizes a real-valued function of a sampled variable.
  4. 4
    Probability notation summarizes when a Boolean condition is true.
  5. 5
    Dm describes the induced probability over m-component tuples formed by independent samples from D.

At a glance

  • D is the distribution governing individual samples from a set.
  • The statement z ∼ D establishes that z is sampled according to D.
  • Expected values summarize real-valued quantities, whereas event probabilities summarize true-or-false conditions.
  • Dm is a distribution over m-component tuples in Zm created by independent sampling from D.

Related concepts

More concepts starting with P