boot_bca_ci {bifurcatingr}R Documentation

Bias-Corrected and Accelerated bootstrap Confidence Interval (BCa) Function.

Description

This function calculates the Bias-Corrected and Accelerated bootstrap (BCa) CI for the least squares estimator of the bifurcating autoregressive model.

Usage

boot_bca_ci(z, p, B = 99, J = 2, conf_level = 0.95)

Arguments

z

a numeric vector containing the tree data.

p

an integer determining the order of bifurcating autoregressive model to be fit to the data.

B

number of bootstrap samples (replicates). Defaults to 99.

J

an integer determining the number of vectors of bootstrap replicates. Defaults to 2.

conf_level

A numeric value representing the confidence level. Defaults to 0.95.

Value

coef

a matrix containing the least squares estimates of the autoregressive coefficients

limits

A numeric vector representing the lower and upper limits of the BCa confidence interval for the autoregressive coefficients of BAR model

Examples

# Generating Non-contaminated normal BAR(1) tree and calculating the BCa CI for
# the autoregressive coefficients of the BAR(1) model
z <- bfa_tree_gen(31, 1, 1, 1, 0.5, 0.5, 0, 10, c(0.7))
boot_bca_ci(z,p=1,B=99,J=2,conf_level=0.95)
# Generating Non-contaminated normal BAR(2) tree and calculating the BCa CI for
# the autoregressive coefficients of the BAR(2) model
z <- bfa_tree_gen(127, 2, 1, 1, 0.5, 0.5, 0, 10, c(0.5, 0.3))
boot_bca_ci(z,p=2,B=99,J=2,conf_level=0.95)

[Package bifurcatingr version 2.1.0 Index]