dchi(x, df)
pchi(q, df)
qchi(p, df)
rchi(n, df)
length(n)
is larger than 1, then length(n)
random values are returned.dchi
), probability (pchi
), quantile (qchi
), or
random sample (rchi
) for the chi distribution with df
degrees of freedom.x
, q
, p
, or df
that are missing will
cause the corresponding elements of the result to be missing.
The chi distribution with $n$ degrees of freedom is the distribution of the
positive square root of a random variable having a
chi-squared distribution with $n$ degrees of freedom.
The chi density function is given by:
predIntNorm
,
Probability Distributions and Random Numbers.# Density of a chi distribution with 4 degrees of freedom, evaluated at 3:
dchi(3, 4)
#[1] 0.1499715
#----------
# The 95'th percentile of a chi distribution with 10 degrees of freedom:
qchi(.95, 10)
#[1] 4.278672
#----------
# The cumulative distribution function of a chi distribution with
# 5 degrees of freedom evaluated at 3:
pchi(3, 5)
#[1] 0.8909358
#----------
# A random sample of 2 numbers from a chi distribution with 7 degrees of freedom.
# (Note: the call to set.seed simply allows you to reproduce this example.)
set.seed(20)
rchi(2, 7)
#[1] 3.271632 2.035179
Run the code above in your browser using DataLab