Learn R Programming

dsfa (version 2.0.2)

mom2par: Moments to Parameters

Description

Calculates the parameters of composed-error distribution based on the provided moments.

Usage

mom2par(mean = 0, sd = 1, skew = 0, s = -1, distr = "normhnorm")

Value

Returns a matrix where the first column corresponds to \(\mu\), the second to \(\sigma_V\) and the third to \(\sigma_U\).

Arguments

mean

numeric vector of means.

sd

numeric vector of standard deviations. Must be positive.

skew

numeric vector of skewness. s*skew must be positive.

s

integer; \(s=-1\) for production and \(s=1\) for cost function.

distr

string; determines the distribution:
`normhnorm`, Normal-halfnormal distribution
`normexp`, Normal-exponential distribution

Details

See dcomper for details of the distribution. For the inverse transformation see par2mom.

Examples

Run this code
mom2par(mean=0, sd=1, skew=-0.5, s=-1, distr="normhnorm")
mom2par(mean=0, sd=1, skew=-1, s=-1, distr="normexp")

Run the code above in your browser using DataLab