Noncentral T Distribution Functions
Source:R/non_central_t_distribution.R
      non_central_t_distribution.RdFunctions to compute the probability density function, cumulative distribution function, and quantile function for the Noncentral T distribution.
Usage
non_central_t_distribution(df, delta)
non_central_t_pdf(x, df, delta)
non_central_t_lpdf(x, df, delta)
non_central_t_cdf(x, df, delta)
non_central_t_lcdf(x, df, delta)
non_central_t_quantile(p, df, delta)Value
A single numeric value with the computed probability density, log-probability density, cumulative distribution, log-cumulative distribution, or quantile depending on the function called.
See also
Boost Documentation for more details on the mathematical background.
Examples
# Noncentral T distribution with 5 degrees of freedom and noncentrality parameter 1
dist <- non_central_t_distribution(5, 1)
# Apply generic functions
cdf(dist, 0.5)
#> [1] 0.3021259
logcdf(dist, 0.5)
#> [1] -1.196912
pdf(dist, 0.5)
#> [1] 0.3360046
logpdf(dist, 0.5)
#> [1] -1.090631
hazard(dist, 0.5)
#> [1] 0.4814687
chf(dist, 0.5)
#> [1] 0.3597165
mean(dist)
#> [1] 1.189416
median(dist)
#> [1] 1.052851
mode(dist)
#> [1] 0.8781834
range(dist)
#> [1] -1.797693e+308  1.797693e+308
quantile(dist, 0.2)
#> [1] 0.165306
standard_deviation(dist)
#> [1] 1.385144
support(dist)
#> [1] -1.797693e+308  1.797693e+308
variance(dist)
#> [1] 1.918623
skewness(dist)
#> [1] 1.26633
kurtosis(dist)
#> [1] 13.32067
kurtosis_excess(dist)
#> [1] 10.32067
# Convenience functions
non_central_t_pdf(0, 5, 1)
#> [1] 0.2302431
non_central_t_lpdf(0, 5, 1)
#> [1] -1.46862
non_central_t_cdf(0, 5, 1)
#> [1] 0.1586553
non_central_t_lcdf(0, 5, 1)
#> [1] -1.841022
non_central_t_quantile(0.5, 5, 1)
#> [1] 1.052851