mde.vonmises: von Mises Minimum Distance Estimates

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

View source: R/mde.vonmises.R

Description

Computes the minimum distance estimates for the parameters of a von Mises distribution: the mean direction and the concentration parameter.

Usage

1
2
3
4
5
6
mde.vonmises(x, bw, mu = NULL, kappa = NULL, n = 512,
  from = circular(0), to = circular(2 * pi), lower = NULL,
  upper = NULL, method = "L-BFGS-B", lower.kappa = .Machine$double.eps,
  upper.kappa = Inf, alpha = NULL, p = 2, control.circular = list(), ...)
## S3 method for class 'mde.vonmises'
print(x, digits = max(3, getOption("digits") - 3), ...)

Arguments

x

a vector. The object is coerced to class circular.

bw

the value of the smoothing parameter.

mu

initial value for the mean direction. Default: maximum likelihood estimate.

kappa

initial value for the concentration parameter. Default: maximum likelihood estimate.

n

number of points used to approximate the density.

from

from which point in the circle the density is approximate.

to

to which point in the circle the density is approximate.

lower

a 2 elements vector passed to optim used to constrained optimization. First element for the mean direction, second element for the concentration.

upper

a 2 elements vector passed to optim used to constrained optimization. First element for the mean direction, second element for the concentration.

method

passed to optim.

lower.kappa

if lower is NULL this parameter is used to constrained optimization for the concentration parameter.

upper.kappa

if upper is NULL this parameter is used to constrained optimization for the concentration parameter.

alpha

if not NULL overrides the value of p. See the next argument p. This is a different parameterization, alpha=-1/2 provides Hellinger distance, alpha=-1 provides Kullback-Leibler distance and alpha=-2 provides Neyman's Chi-Square distance.

p

p=2 provides Hellinger distance, p=-1 provides Kullback-Leibler distance and p=Inf provides Neyman's Chi-Square distance. It is ignored if alpha is not NULL.

control.circular

the attribute of the resulting object (mu)

digits

integer indicating the precision to be used.

...

further parameters in print.mde.vonmises.

Details

The distance from an estimated density (by the non parametric kernel density estimator) and the model is evaluated by simple rectangular approximation. optim is used to performs minimization.

Value

Returns a list with the following components:

call

the match.call().

mu

the estimate of the mean direction.

kappa

the estimate of the concentration parameter.

dist

the distance between the estimated density and the model.

data

the original supplied data converted in radians, clockwise and zero at 0.

x

the 'n' coordinates of the points where the density is estimated.

y

the estimated density values.

k

the density at the model.

Author(s)

Claudio Agostinelli

References

C. Agostinelli. Robust estimation for circular data. Computational Statistics & Data Analysis, 51(12):5867-5875, 2007.

See Also

circular, mle.vonmises and wle.vonmises.

Examples

1
2
3
4
5
6
7
8
set.seed(1234)
x <- c(rvonmises(n=200, mu=circular(0), kappa=10), rvonmises(n=20, mu=circular(pi/2), kappa=20))
res <- mde.vonmises(x, bw=500, mu=circular(0), kappa=10)
res
plot(circular(0), type='n', xlim=c(-1, 1.75), shrink=1.2)
lines(circular(res$x), res$y)
lines(circular(res$x), res$k, col=2)
legend(1,1.5, legend=c('estimated density', 'MDE'), lty=c(1, 1), col=c(1, 2))

wle documentation built on May 29, 2017, 11:48 a.m.

Related to mde.vonmises in wle...