Categorical Distribution
📂Probability DistributionCategorical Distribution
Definition
Given a sample space with k(≥2) categories, Ω={1,2,…,k}, and a probability vector p=(p1,…,pk), the discrete probability distribution with the following probability mass function is called the Categorical distribution.
p(x=i)=pi,x∈{1,2,…,k}
Description
The probability of each of the k categories occurring is represented by p=(p1,…,pk). Therefore, p must satisfy the following condition.
i=1∑kpi=1,pi≥0
If the Bernoulli distribution is compared to “flipping a coin once,” the Categorical distribution can be compared to “rolling a die once.”
Ω={
,
,
,
,
,
}
p=(61,61,61,61,61,61)
The following notation is used.
Cat(k;p1,…,pk)=Cat(k;p)
The Categorical distribution can be considered a generalization of categories from the Bernoulli distribution to k categories. Further generalizing to n trials leads to the Multinomial distribution.
The probability mass function can also be expressed as follows.
p(j)=i=1∏kpiδji=i=1∑kδjipi,j∈{1,2,…,k}
δji refers to the Kronecker delta.
Meanwhile, the sample space can be viewed as the standard basis of Euclidean space, and each realization can be considered as a one-hot vector. In this case, with a random vector x=(x1,…,xk) satisfying the probability mass function, the Categorical distribution can be expressed as Cat(x;p).
xi∈{0,1},i=1∑kxi=1
p(x)=p(x1,…,xk)=i=1∏kpixi