Learn R Programming

rray (version 0.0.0.9000)

rray_erf: Error and gamma functions

Description

  • rray_erf() - Error function

  • rray_erfc() - Complementary error function

  • rray_gamma() - Gamma function

  • rray_lgamma() - Natural log of the absolute value of the gamma function

  • rray_digamma() - First derivative of the logarithm of the gamma function

  • rray_trigamma() - Second derivative of the logarithm of the gamma function

Usage

rray_erf(x)

rray_erfc(x)

rray_gamma(x)

rray_lgamma(x)

rray_digamma(x)

rray_trigamma(x)

Arguments

x

A vector, matrix, array or rray.

Details

For more in depth details describing the gamma functions, see ?gamma.

rray_gamma(0) returns Inf, while gamma(0) returns NaN. The rray behavior matches the IEEE standard defined in the error handling section of the tgamma() C++ definition.

Examples

Run this code
# NOT RUN {
x <- matrix(c(2, 4, 6))

rray_erf(x)
rray_erfc(x)

rray_gamma(x)
rray_lgamma(x)
rray_digamma(x)
rray_trigamma(x)

# }

Run the code above in your browser using DataLab