The probability symbol in LaTeX is \Pr or \mathbb{P}, and the expectation operator is \mathbb{E}[X]. The table lists the eight commands people use most, with the package each one needs; the full list of probability and statistics symbols follows below.
| Symbol | Command | Use | Package | Copy |
|---|---|---|---|---|
\Pr(A) | Probability operator (upright Pr) | built in | ||
\mathbb{P}(A) | Probability symbol, blackboard bold | amssymb | ||
\mathbb{E}[X] | Expectation operator | amssymb | ||
\operatorname{Var}(X) | Variance | amsmath | ||
\operatorname{Cov}(X, Y) | Covariance | amsmath | ||
P(A \mid B) | Conditional probability | built in | ||
X \sim \mathcal{N}(\mu, \sigma^2) | Distributed as (normal) | built in | ||
\binom{n}{k} | Binomial coefficient | amsmath |
Probability notation starts with the probability operator. LaTeX ships \Pr, which typesets an upright “Pr” with operator spacing, while most papers use blackboard bold \mathbb{P} for probability and \mathbb{E} for expectation, as in \mathbb{E}[X]. Conditional probability uses the vertical bar \mid, which gets the right spacing where a plain | does not: P(A \mid B). A random variable’s distribution is written with \sim, for example X \sim \mathcal{N}(\mu, \sigma^2), and \propto says a density is proportional to something.
Variance and covariance are not built in, so write them as operators: \operatorname{Var}(X) and \operatorname{Cov}(X, Y) from amsmath, or declare them once in the preamble with \DeclareMathOperator{\Var}{Var}. The parameters themselves are Greek letters: \mu, \sigma, \rho, \lambda and \theta, with estimates marked by \hat{\theta} and sample means by \bar{x}. Binomial coefficients come from amsmath’s \binom{n}{k}, chi-squared is \chi^2, and independence is usually \perp or the double symbol \perp\!\!\!\perp.
Load \usepackage{amsmath, amssymb} for \mathbb, \operatorname and \binom. For the full alphabet see our guide to Greek letters and math symbols and the page on math functions and operators.
\mathbb{P}P(A)\mathbb{E}[X]E[X]\text{Var}(X)\text{Cov}(X,Y)\sigma\mu\bar{x}\sim\mathcal{N}(\mu, \sigma^2)\perp\perp\!\!\!\perp\midP(A \mid B)\rho\chi^2\binom{n}{k}\propto