| Type: | Package | 
| Title: | Broken Adaptive Ridge Regression with Cyclops | 
| Version: | 1.0.1 | 
| Date: | 2025-07-21 | 
| Maintainer: | Marc A. Suchard <msuchard@ucla.edu> | 
| Description: | Approximates best-subset selection (L0) regression with an iteratively adaptive Ridge (L2) penalty for large-scale models. This package uses Cyclops for an efficient implementation and the iterative method is described in Kawaguchi et al (2020) <doi:10.1002/sim.8438> and Li et al (2021) <doi:10.1016/j.jspi.2020.12.001>. | 
| License: | Apache License 2.0 | 
| Depends: | R (≥ 3.2.2), Cyclops (≥ 3.0.0) | 
| Imports: | futile.logger, bit64 | 
| Suggests: | testthat, survival, knitr, rmarkdown | 
| Encoding: | UTF-8 | 
| RoxygenNote: | 7.3.2 | 
| NeedsCompilation: | no | 
| Packaged: | 2025-07-23 16:32:53 UTC; msuchard | 
| Author: | Marc A. Suchard [aut, cre], Eric Kawaguchi [aut], Ning Li [aut], Gang Li [aut], Observational Health Data Sciences and Informatics [cph] | 
| Repository: | CRAN | 
| Date/Publication: | 2025-07-23 17:10:02 UTC | 
Create a BAR Cyclops prior object
Description
createBarPrior creates a BAR Cyclops prior object for use with fitCyclopsModel.
Usage
createBarPrior(
  penalty = "bic",
  exclude = c(),
  forceIntercept = FALSE,
  fitBestSubset = FALSE,
  initialRidgeVariance = 10000,
  tolerance = 1e-08,
  maxIterations = 10000,
  threshold = 1e-06,
  delta = 0
)
Arguments
penalty | 
 Specifies the BAR penalty; possible values are 'BIC' or 'AIC' or a numeric value  | 
exclude | 
 A vector of numbers or covariateId names to exclude from prior  | 
forceIntercept | 
 Logical: Force intercept coefficient into regularization  | 
fitBestSubset | 
 Logical: Fit final subset with no regularization  | 
initialRidgeVariance | 
 Numeric: variance used for algorithm initiation  | 
tolerance | 
 Numeric: maximum abs change in coefficient estimates from successive iterations to achieve convergence  | 
maxIterations | 
 Numeric: maxium iterations to achieve convergence  | 
threshold | 
 Numeric: absolute threshold at which to force coefficient to 0  | 
delta | 
 Numeric: change from 2 in ridge norm dimension  | 
Value
A BAR Cyclops prior object of class inheriting from
"cyclopsPrior" for use with fitCyclopsModel.
Examples
prior <- createBarPrior(penalty = "bic")
Create a fastBAR Cyclops prior object
Description
createFastBarPrior creates a fastBAR Cyclops prior object for use with fitCyclopsModel.
Usage
createFastBarPrior(
  penalty = 0,
  exclude = c(),
  forceIntercept = FALSE,
  fitBestSubset = FALSE,
  initialRidgeVariance = 10000,
  tolerance = 1e-08,
  maxIterations = 10000,
  threshold = 1e-06
)
Arguments
penalty | 
 Specifies the BAR penalty  | 
exclude | 
 A vector of numbers or covariateId names to exclude from prior  | 
forceIntercept | 
 Logical: Force intercept coefficient into regularization  | 
fitBestSubset | 
 Logical: Fit final subset with no regularization  | 
initialRidgeVariance | 
 Numeric: variance used for algorithm initiation  | 
tolerance | 
 Numeric: maximum abs change in coefficient estimates from successive iterations to achieve convergence  | 
maxIterations | 
 Numeric: maximum iterations to achieve convergence  | 
threshold | 
 Numeric: absolute threshold at which to force coefficient to 0  | 
Value
A BAR Cyclops prior object of class inheriting from
"cyclopsPrior" for use with fitCyclopsModel.
Examples
nobs = 500; ncovs = 100
prior <- createFastBarPrior(penalty = log(ncovs), initialRidgeVariance = 1 / log(ncovs))