Code Monkey home page Code Monkey logo

microbvs's Introduction

In this folder you'll find code for the R package MicroBVS found in:

“MicroBVS: Dirichlet-Tree Multinomial Regression Models with Bayesian Variable Selection - an R Package” (Accepted by BMC Bioinformatics 2020), by MD Koslovsky and M Vannucci

The main functions operate in C++ via the R package Rcpp. These functions can be sourced by a set of wrapper functions that enable easy implementation of the code in the R environment. Various functions are available that produce, summarize, and plot the results for inference.  

This package relies on various R packages that need to be installed in the R environment before running. To install, use the install.packages(‘’) command for the following packages:
Rcpp 
RcppArmadillo  
MCMCpack
mvtnorm 
ggplot2
devtools
ape
igraph

Then to install the MicroBVS package, simply run 

library(devtools)
install_github( "mkoslovsky/MicroBVS", build_vignettes = TRUE)

in the R console. 

Additionally in this folder, you will find code for 

"A Bayesian model of microbiome data for simultaneous identification of covariate associations and prediction of phenotypic outcomes" (Accepted by AOAS) by MD Koslovsky, KL Hoffman, CR Daniel and M Vannucci

As of 9/6/23, this version of the joint model corrects the update of the auxiliary parameters c_ij in the original version. Specifically, the previous Gibbs update has been replaced with a MH update. Following this change, the selection, fit, and prediction performance of the model is largely unaffected. However, the computation time does increase with the new sampler. To speed up the sampler, we also implemented a `full` version that updates the regression coefficients and variance term in the linear portion of model. Computationally, this step actually speeds up the sampler as the likelihood component in the revised MH update is greatly simplified. Additionally, we provide functionality to only update a proportion of c_ij in each iteration with a 'rate' parameter, which ranges from 0 to 1, following Cassese et al 2014. In simulation, we found that setting rate to 0.50 or above typically gave comparable results. Please reach out to the corresponding author for more details. 


Lastly, you will also find code for

"A Bayesian joint model for compositional mediation effect selection in microbiome data" by J Fu, MD Koslovsky, AM Neophytou, M Vannucci published in Statistics in Medicine.
This function provides options to cut the feedback from the outcome model to the DM portion of the model as presented in the original manuscript, or incorporate potential feedback, similar to the joint model above.

Please see the accommpanying vignettes for details of how to run each model and perform inference. 




References: 
Cassese, A., Guindani, M., Tadesse, M. G., Falciani, F. and Vannucci, M. (2014). A
hierarchical Bayesian model for inference of copy number variants and their association
to gene expression. The Annals of Applied Statistics 8 148.

microbvs's People

Contributors

mkoslovsky avatar marinavannucci avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.