parametersGamma: Alternate Gamma Parametrization

View source: R/SGAT.R

parametersGammaR Documentation

Alternate Gamma Parametrization

Description

Calculate shape and rate parameters of the Gamma distribution

Usage

parametersGamma(mean, sd)

Arguments

mean

vector of means.

sd

vector of standard deviations.

Details

The Gamma distribution is usually parameterized in terms of the shape and rate parameters. The parametersGamma function deterimines the shape and rate parameters that will yield a Gamma distribution with a desired mean and standard deviation.

Value

Returns a 2 column array of the shape and rate parameters that will yield the required mean and standard deviation.

Examples

## Shape and rate that give a mean of 3 and sd of 2
parametersGamma(3,2)

SWotherspoon/SGAT documentation built on June 1, 2022, 10:49 p.m.