bw.joint.dpcirc {NPCirc}R Documentation

Smoothing parameter selection for circular double Poisson regression

Description

Function bw.joint.dpcirc provides the smoothing parameters for the nonparametric joint estimator of the mean and dispersion functions when the conditional density is a double Poisson. It performs a joint cross-validation search.

Usage

bw.joint.dpcirc(x, y, startvmu = NULL, startvgam = NULL, lower=c(0.05,0.05), 
  upper=c(50,7),tol = 0.00001, maxit = 300)

Arguments

x

Vector of data for the independent variable. The object is coerced to class circular.

y

Vector of data for the dependent variable. This must be same length as x and should contain counts.

startvmu

Vector of length two containing the initial values for the parameters corresponding to the estimation of the mean.

startvgam

Vector of length two containing the initial values for the parameters corresponding to the estimation of the dispersion.

lower, upper

Vectors of length two with the lower and upper boundaries of the intervals to be used in the search for the values of the smoothing parameters. The first component of each corresponds to the parameter associated to the estimation of the mean, while the second component corresponds to the estimation of the dispersion.

tol

Tolerance parameter for convergence in the numerical estimation.

maxit

Maximum number of iterations in the numerical estimation.

Details

See Alonso-Pena et al. (2022) for details.

The NAs will be automatically removed.

Value

A vector of length two with the first component being the value of the smoothing parameter associated to the mean estimation and with the second component being the value of the smoothing parameter associated to the dispersion estimation.

Author(s)

Maria Alonso-Pena, Irene Gijbels and Rosa M. Crujeiras

References

Alonso-Pena, M., Gijbels, I. and Crujeiras, R.M. (2022). Flexible joint modeling of mean and dispersion for the directional tuning of neuronal spike counts. Under review.

See Also

kern.dpreg.circ

Examples


data(spikes)
direction<-circular(spikes$direction,units="degrees")
counts<-spikes$counts
bw.joint.dpcirc(direction, counts, lower=c(0.5,0.5), upper=c(50,7))


[Package NPCirc version 3.1.1 Index]