Get Started »

# Statistics

In the Wolfram Language, statistical functions accept either lists or symbolic distributions as an argument.

Compute the mean of a list of numbers:

 In[1]:= ⨯ `Mean[{1, 2, 4, 5}]`
 Out[1]=

Find the correlation of multiple lists:

 In[2]:= ⨯ `Correlation[{1, 3, 5}, {6, 4, 2}]`
 Out[2]=

Find the standard deviation of a Poisson distribution:

 In[3]:= ⨯ `StandardDeviation[PoissonDistribution[2]]`
 Out[3]=

Calculate the moment of a list of symbols:

 In[1]:= ⨯ `Moment[{x, y, z}, 2]`
 Out[1]=

Get the moment-generating function for a distribution:

(Type ESCmESC for `μ` and ESCsESC for `σ`.)
 In[2]:= ⨯ `MomentGeneratingFunction[NormalDistribution[\[Mu], \[Sigma]], t]`
 Out[2]=

Generate statistical data with RandomVariate:

(Use //Short to get a short summary of output.)
 In[1]:= ⨯ `RandomVariate[NormalDistribution[0, 1], {500, 2}] // Short`
 Out[1]=

Visualize the resulting data:

 In[2]:= ⨯ `Histogram3D[%]`
 Out[2]=

QUICK REFERENCE: Statistical Moments and Generating Functions `»`

QUICK REFERENCE: Statistical Visualization `»`