gnlFitStart: Find Starting Values for Fitting a Generalised Normal Laplace...

Description Usage Arguments Details Value Author(s) See Also Examples

Description

Finds starting values for input to a maximum likelihood routine for fitting a Generalised Normal Laplace distribution to data.

Usage

1
2
3
4
5
  gnlFitStart(x, breaks = "FD",
              paramStart = NULL,
              startValues = c("MoM", "US"),
              startMethodMoM = "Nelder-Mead", ...)
  gnlFitStartMoM(x, startMethodMoM = "Nelder-Mead", ...)

Arguments

x

Data vector.

breaks

Breaks for histogram. If missing, defaults to those generated by hist(x, right = FALSE, plot = FALSE).

paramStart

Starting values for parameter vector if startValues = "US".

startValues

Vector of the different starting value methods to consider. See Details.

startMethodMoM

Method used by call to optim in finding method of moments estimates.

...

Passes arguments to optim.

Details

Possible values of the argument startValues are the following:

If startValues = "US" then a value must be supplied for paramStart.

If startValues = "MoM", gnlFitStartMoM is called.

If startValues = "MoM" an initial optimisation is needed to find the starting values. These optimisations call optim.

Value

gnlFitStart returns a list with components:

paramStart

A vector with elements mu, sigma, alpha, beta and rho giving the starting value of param.

xName

A character string with the actual x argument name.

breaks

The cell boundaries found by a call to hist.

midpoints

The cell midpoints found by a call to hist.

empDens

The estimated density found by a call to hist.

gnlFitStartMoM returns only the method of moments estimates as a vector with elements mu, sigma, alpha, beta, rho.

Author(s)

David Scott d.scott@auckland.ac.nz, Simon Potter

See Also

dgnl, gnlFit, hist, and optim.

Examples

1
2
3
param <- c(2, 2, 1, 1, 1)
dataVector <- rgnl(500, param = param)
gnlFitStart(dataVector, startValues = "MoM")

sjp/NormalLaplace documentation built on May 30, 2019, 12:06 a.m.