Function Repository Resource:

WishartDistribution

Represent the Wishart distribution

Contributed by: Wolfram Research
 ResourceFunction["WishartDistribution"][Σ,m] represents a Wishart distribution with scale matrix Σ and degrees of freedom parameter m.

Details and Options

The probability density for a symmetric positive definite matrix x in a Wishart distribution is proportional to .
The scale matrix Σ can be any symmetric positive definite matrix. The parameter m can be any number such that m>Length[Σ].
For integer m, the Wishart distribution gives the distribution of covariance matrices of multinormal samples.
ResourceFunction["WishartDistribution"] can be used with such functions as Mean, PDF and RandomReal.

Examples

Basic Examples

The mean of a Wishart distribution:

 In[1]:=
 Out[1]=

The variance:

 In[2]:=
 Out[2]=

Probability density function:

 In[3]:=
 Out[3]=

Scope

Generate a set of pseudorandom matrices that follow a Wishart distribution:

 In[4]:=
 Out[4]=

 In[5]:=
 Out[5]=

 In[6]:=
 Out[6]=

Possible Issues

WishartDistribution is not defined when Σ is not symmetric and positive definite:

 In[7]:=
 Out[7]=

WishartDistribution is not defined when m<Length[Σ]:

 In[8]:=
 Out[8]=

Substitution of invalid parameters into symbolic outputs gives results that are not meaningful:

 In[9]:=
 Out[9]=

Requirements

Wolfram Language 11.3 (March 2018) or above