This function plots the CircSiZer map for circular regression estimation based on circular kernel methods, as described in Oliveira et al. (2013). The CircSiZer is an extension of SiZer proposed by Chaudhuri and Marron (1999) to circular data.
circsizer.regression(x, y, bws=NULL, adjust=2, ngrid=150, alpha=0.05, B=500,
B2=250, log.scale=TRUE, display=TRUE)An object with class circsizer whose underlying structure is a list containing the following components.
Original dataset.
Number of equally spaced angles where the derivative of the regression estimator is evaluated.
Vector of smoothing parameters (given in \(-\log_{10}\) scale if log.scale=TRUE).
Logical; if TRUE, the \(-\log_{10}\) scale is used for constructing the CircSiZer map.
List containing: a matrix with lower limits fot the confidence intervals; a matrix with the lower limits of the confidence intervals; a matrix with the Effective Sample Size. Each row corresponds to each value of the smoothing parameter and each column corresponds to an angle.
Matrix containing the colors for plotting the CircSiZer map.
If display==TRUE, the function also returns the CircSiZer map for regression.
Vector of data for the independent variable. The object is coerced to class circular.
Vector of data for the dependent variable. This must be same length as x.
Vector of smoothing parameters. Values of bws must be positive. bws will be coerced to be equally spaced. Length of vector bws
must be at least 2.
If bws=NULL, the smoothing parameters used are adjust/bw and adjust*bw, where bw is the smoothing parameter obtained
by using the cross--validation rule.
Integer indicating the number of equally spaced angles between \(0\) and \(2\pi\) where the estimator is evaluated. Default
ngrid=150.
Significance level for the CircSiZer map. Default alpha=0.05.
Integer indicating the number of bootstrap samples to estimate the standard deviation of the derivative estimator. Default B=500.
Integer indicating the number of bootstrap samples to compute the denominator in Step 2 of algorithm described in Oliveira et al. (2013).
Default B=250.
Logical, if TRUE, the CircSiZer map is plotted in the scale \(-\log_{10}(\code{bws})\). Default is TRUE.
Logical, if TRUE, the CircSiZer map is plotted. Default is TRUE.
Maria Oliveira, Rosa M. Crujeiras and Alberto Rodriguez--Casal
See Details Section of circsizer.density.
The NAs will be automatically removed.
Chaudhuri, P. and Marron, J.S. (1999). SiZer for exploration of structures in curves, Journal of the American Statistical Association, 94, 807--823.
Oliveira, M., Crujeiras, R.M. and Rodriguez--Casal (2014) CircSiZer: an exploratory tool for circular data. Environmental and Ecological Statistics, 21, 143--159.
Oliveira, M., Crujeiras R.M. and Rodriguez--Casal, A. (2014) NPCirc: an R package for nonparametric circular methods. Journal of Statistical Software, 61(9), 1--26. https://www.jstatsoft.org/v61/i09/
circsizer.map
if (FALSE) {
set.seed(2012)
n <- 100
x <- seq(0,2*pi,length=n)
y <- sin(x)+sqrt(0.5)*rnorm(n)
circsizer.regression(circular(x), y, bws=seq(10,60,by=5))
}
Run the code above in your browser using DataLab