Giter Site home page Giter Site logo

xec-cm / ancom Goto Github PK

View Code? Open in Web Editor NEW

This project forked from frederickhuanglin/ancom-code-archive

0.0 0.0 0.0 1.11 MB

R scripts for Analysis of Composition of Microbiomes (ANCOM).

Home Page: https://www.tandfonline.com/doi/full/10.3402/mehd.v26.27663

License: Other

R 100.00%

ancom's Introduction

User Manual for ANCOM v2.1

R-CMD-check DOI

The current code implements ANCOM in cross-sectional and longitudinal datasets while allowing the use of covariates.

Installation

To get a bug fix or to use a feature from the development version, you can install the development version of ANCOM from GitHub.

if(!requireNamespace("devtools")){
  install.packages("devtools")
}

devtools::install_github("xec-cm/ANCOM")

Usage

library(ANCOM)

# Step 0: Load or define input data

feature_table <- ANCOM:::moving_pics_table_taxa
meta_data <- ANCOM:::moving_pics_sample_metadata

# Step 1: Data Preprocessing

prepro <- feature_table_pre_process(
  feature_table = feature_table,
  meta_data = meta_data,
  sample_var = "Sample.ID",
  group_var = NULL,
  out_cut = 0.05,
  zero_cut = 0.90,
  lib_cut = 1000,
  neg_lb = FALSE
)

# Step 2: ANCOM

res <- ANCOM(
  feature_table = prepro$feature_table, 
  meta_data = prepro$meta_data,
  struc_zero = prepro$structure_zeros, 
  main_var = "Subject", 
  p_adj_method = "BH", 
  alpha = 0.05, 
  adj_formula = NULL, 
  rand_formula = NULL
)

res$fig

Getting help

If you encounter a clear bug, please file an issue with a minimal reproducible example on GitHub.

Code of Conduct

Please note that the ANCOM project is released with a Contributor Code of Conduct. By contributing to this project, you agree to abide by its terms.

ancom's People

Contributors

frederickhuanglin avatar xec-cm 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.