Categories &

Functions List

Function Reference: hnlike

statistics: nlogL = hnlike (params, x)
statistics: [nlogL, acov] = hnlike (params, x)
statistics: [nlogL, acov] = hnlike (params, x, freq)

Negative log-likelihood for the half-normal distribution.

nlogL = hnlike (params, x) returns the negative log likelihood of the data in x corresponding to the half-normal distribution with (1) location parameter mu and (2) scale parameter sigma given in the two-element vector params.

[nlogL, acov] = hnlike (params, x) returns the inverse of Fisher’s information matrix, acov. If the input parameter values in params are the maximum likelihood estimates, the diagonal elements of params are their asymptotic variances.

[…] = hnlike (params, x, freq) accepts a frequency vector, freq, of the same size as x. freq typically contains integer frequencies for the corresponding elements in x, but it can contain any non-integer non-negative values. By default, or if left empty, freq = ones (size (x)).

The half-normal CDF is only defined for x >= mu.

Further information about the half-normal distribution can be found at https://en.wikipedia.org/wiki/Half-normal_distribution

See also: hncdf, hninv, hnpdf, hnrnd, hnfit, hnstat

Source Code: hnlike