Skip to content

Development for Bayesian Survival Models Package

Notifications You must be signed in to change notification settings

lanyuzhang16/causalBETA

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

causalBETA

The paper associated with this package is on arXiv: https://arxiv.org/abs/2310.12358.


About

The R package causalBETA is an MCMC-based implementation of piecewise exponential model for survival data, and it uses G-computation to conduct causal inference for binary treatment on survival data. We provide generic plot functions to visualize estimates easily and allow users to run MCMC diagnostics by coda package.

Installation

install using devtools package

## install.packages(devtools) ## make sure to have devtools installed 
devtools::install_github("RuBBiT-hj/causalBETA")
library(causalBETA)

Dependency

The following packages are required for causalBETA:

  • cmdstanr ≥ 0.5.3
  • coda
  • mets
  • survival
  • LaplacesDemon
  • stats
  • rlang
  • grDevices
  • graphics

This information is also listed in DESCRIPTION.

Documentation and Examples

The paper associated with this package contains the statistical details of the model as well as a detailed walk-through demonstration.

Help documentation in R is also available, and it has example code for each function. After installing the package and loading it with library(causalBETA), use ? to access help documentation for specific functions. For example, for the two main functions:

?causalBETA::bayeshaz     # Construct the MCMC-based Bayesian piece-wise exponential model
?causalBETA::bayesgcomp   # Apply G-computation to obtain posterior draws of the average difference in survial probabilities between two treatments

The code for demostration in the paper is available in the folder demo_code.

Reporting Issues

If you encounter any bugs or have feature requests, please open an issue on GitHub.

Citation

Please use the following LaTex cite as follows:

@misc{ji2023causalbeta,
      title={causalBETA: An R Package for Bayesian Semiparametric Causal Inference with Event-Time Outcomes}, 
      author={Han Ji and Arman Oganisian},
      year={2023},
      eprint={2310.12358},
      archivePrefix={arXiv},
      primaryClass={stat.ME}
}

Contact

The corresponding package author are Han Ji (email: [email protected]) and Arman Oganisian (email: [email protected]).

About

Development for Bayesian Survival Models Package

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • R 97.0%
  • Stan 3.0%