wle.wrappednormal {wle} | R Documentation |
Computes the weighted likelihood estimates for the parameters of a Wrapped Normal distribution: the mean direction and the concentration parameter (and the scale parameter).
wle.wrappednormal(x, mu, rho, sd, K, boot = 30, group, num.sol = 1, raf = "HD", smooth = 0.0031, tol = 10^(-6), equal = 10^(-3), min.sd = 0.001, min.k = 10, max.iter = 100, use.smooth = TRUE, alpha=NULL, p = 2, verbose = FALSE, control.circular=list()) ## S3 method for class 'wle.wrappednormal': print(x, digits = max(3, getOption("digits") - 3), ...)
x |
a vector. The object is coerced to class
circular . |
mu |
if a values if provided the parameter is considered known. |
rho |
if a values if provided the parameter (and sd ) is
considered known. |
sd |
if a values if provided the parameter (and rho ) is
considered known. |
K |
number of elements used to approximate the density of the wrapped normal. |
boot |
the number of starting points based on boostrap subsamples to use in the search of the roots. |
group |
the dimension of the bootstap subsamples. |
num.sol |
maximum number of roots to be searched. |
raf |
type of Residual adjustment function to be use:
raf="HD" : Hellinger Distance RAF,
raf="NED" : Negative Exponential Disparity RAF,
raf="SCHI2" : Symmetric Chi-Squared Disparity RAF. |
smooth |
the value of the smoothing parameter. |
tol |
the absolute accuracy to be used to achieve convergence of the algorithm. |
equal |
the absolute value for which two roots are considered the
same. (This parameter must be greater than tol ). |
min.sd |
minimum value for the sd parameter. |
min.k |
minimum number of elements used to approximate the density of the wrapped normal. |
max.iter |
maximum number of iterations. |
use.smooth |
logical, if TRUE a smoothed model is used,
default is TRUE . |
alpha |
see the next argument p . This is a different
parameterization, alpha=-1/2 provides Hellinger Distance RAF,
alpha=-1 provides Kullback-Leibler RAF and alpha=-2
provides Neyman's Chi-Square RAF. |
p |
this parameter works only when raf="HD" . p=2
provide Hellinger Distance RAF, p=-1
provide Kullback-Leibler RAF and p=Inf provide Neyman's
Chi-Square RAF. |
verbose |
logical, if TRUE warnings are printed. |
control.circular |
the attribute of the resulting objects (mu ) |
digits |
integer indicating the precision to be used. |
... |
further parameters in print.wle.vonmises . |
Parameters p
and raf
will be change in the future. See
the reference below for the definition of all the RAF.
Returns a list with the following components:
call |
the match.call(). |
mu |
the estimate of the mean direction or the value supplied. If
num.sol > 1 then mu may have length greater than 1, i.e, one value for each root found. |
rho |
the estimate of the concentration parameter or the
value supplied. If num.sol > 1 then rho may have length
greater than 1, i.e, one value for each root found. |
sd |
the estimate of the standard deviation parameter or the
value supplied. If num.sol > 1 then sd may have length
greater than 1, i.e, one value for each root found. |
tot.weights |
the sum of the weights divide by the number of observations, one value for each root found. |
weights |
the weights associated to each observation, one column vector for each root found. |
f.density |
the non-parametric density estimation. |
m.density |
the smoothed model. |
delta |
the Pearson residuals. |
tot.sol |
the number of solutions found. |
not.conv |
the number of starting points that does not converge after the max.iter iteration are reached. |
Claudio Agostinelli
C. Agostinelli (2003) Robust Estimation for Circular Data, manuscript.
if (require(circular)) { x <- c(rwrappednormal(n=50, mu=circular(0), sd=1), rwrappednormal(n=5, mu=circular(pi/2), sd=0.5)) wle.wrappednormal(x, smooth=1/20, group=5) } else { cat("Please, install the package 'circular' in order to use this function.\n") }