chorussell.bs: Bootstrap procedure for the 'chorussell' procedure

View source: R/chorussell.R

chorussell.bsR Documentation

Bootstrap procedure for the chorussell procedure

Description

This function carries out the bootstrap procedure of the chorussell procedure. This function supports parallel programming via the future_map function.

Usage

chorussell.bs(
  data,
  lpmodel,
  beta.tgt,
  R,
  maxR,
  kappa,
  norm,
  n,
  estimate,
  solver,
  progress
)

Arguments

data

An data frame or a matrix.

lpmodel

The lpmodel object.

beta.tgt

The value to be tested.

R

The number of bootstrap replications.

maxR

The maximum number of bootstrap replications to be considered in case there are some errors.

kappa

The tuning parameter used in the second step of the two-step procedure for obtaining the bounds subject to the shape constraints. It can be any nonnegative number or a vector of nonnegative numbers.

norm

The norm used in the optimization problem. It can be either a 1-norm or a 2-norm. See the details section of estbounds for a list of accepted strings.

n

The sample size. This is only required if data is omitted in the input.

estimate

A boolean variable to indicate whether the bounds should be estimated or not.

solver

The name of the linear and quadratic programming solver that is used to obtain the solution to linear and quadratic programs. The solvers supported by this package are cplexAPI, gurobi, limSolve and Rcplex.

progress

The boolean variable for whether the progress bars should be displayed. If it is set as TRUE, the progress bars will be displayed while the code is running.

Value

Returns a list of output that are obtained from the Cho-Russell procedure:

ub.bs

The list of upper bounds from bootstrap data.

lb.bs

The list of lower bounds from bootstrap data.

df.error

A table showing the id of the bootstrap replication(s) with error(s) and the corresponding error message(s).

error.list

A list of error messages.

R.eval

The number of bootstrap replications that have been conducted.

R.succ

The number of successful bootstrap replications.


conroylau/lpinfer documentation built on Oct. 23, 2022, 9:21 a.m.