Statistics Toolbox
  Go to function:
    Search    Help Desk 
chi2pdf    Examples

Chi-square (2) probability density function (pdf).

Syntax

Description

chi2pdf(X,V) computes the 2 pdf with parameter V at the values in X. The arguments X and V must be the same size except that a scalar argument functions as a constant matrix of the same size of the other argument.

The degrees of freedom, V, must be a positive integer.

The chi-square pdf is:


The 2 density function with n degrees of freedom is the same as the gamma density function with parameters n/2 and 2.

If x is standard normal , then x2 is distributed 2 with one degree of freedom. If x1, x2, ..., xn are n independent standard normal observations, then the sum of the squares of the x's is distributed 2 with n degrees of freedom.

Examples

The mean of the 2 distribution is the value of the parameter, nu. The above example shows that the probability density of the mean falls as nu increases.



[ Previous | Help Desk | Next ]