Skip to content

Code for analyzing data in the C. difficile Biolog manuscript by Midani et al.

License

Notifications You must be signed in to change notification settings

firasmidani/cdiff-biolog-growth

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Emerging Clostridioides difficile ribotypes have divergent metabolic phenotypes

Description

This is a project repository for the analysis of C. difficile growth data under various nutritional conditions. It includes code for analyzing the microbial growth data and generating figures for related manuscript.

Data can be found on Zenodo at https://zenodo.org/records/12626877

The repository contains the following folders:

  • configs includes various meta-data tables, needed for analyzing data and generating figures.
  • code/analyze-data: Code for analyzing the data. It includes a driver bash script (driver.sh)
  • code/generate-figures: Code for generating the figures. It includes a driver bash script (driver.sh)

Requirements

Analyses were performed with AMiGA, Python 3.12.8, and R 4.3.31. The YAML environment files list all Python and R packages used in addition to their exact version numbers. The driver.sh scripts will prompt mamba to create these environments. If you use conda, you will need to replace all mamba instances with conda (see step 6 below).

Instructions for reproducing data analysis and figure generation

If you would like to reproduce the data analysis and figure generation, do the following:

1) Download or clone this repository

2) Download data and de-compress data

Transfer and unzip all folders that begin with the word amiga from the Zendo repository into this GitHub repository. These folder will already include both the raw data and the analysis outputs by AMiGA. When you re-run the analysis, you will over-write these outputs.

4) Organize your working directory

You should have the following structure:

   cdiff-biolog-grwoth
   │
   ├── LINCENSE
   ├── README.md     
   ├── amiga-biolog
   ├── amiga-clade-5
   ├── amiga-ribotype-255
   ├── amiga-validation
   ├── amiga-yeast-extract-biolog
   ├── amiga-yeast-extract-validation
   ├── code
   │     ├── analyze-data
   │     ├── environment-amiga.yml
   │     ├── environment-python.yml
   │     ├── environment-r.yml
   │     └── generate-figures
   └── configs

5) Install AMiGA

Install AMiGA. Then, revise line 5 in code/analyze-data/driver.sh to point to the amiga.py file in your machine.

6) Create conda environments

You can use the provided YAML files to do so. You can use either conda, mamba, or micromamba. I used mamba for managing the environments used for this study. The cdiff-biolog-amiga has the same requirements as the ones used by AMiGA software. It is the environment necessary for code in the code/anayze-data portion of this repository. On the other hand, the cdiff-biolog-python and cdiff-biolog-r are the environments necessary for code in the code/generate-figures portion.

In the next step, the driver.sh scripts will prompt mamba to create these environments. If you use conda, you will need to replace all mamba instances with conda. You can do this programmatically with the followign command

find /path/to/directory -type f -name "*.sh" -exec sed -i '' -E 's/mamba (--version|list|env )/conda \1/g' {} +

7) Analyze data

Analyzer data with sh cdiff-biolog-grwoth/code/analyze-data/driver.sh. Most output will be generated in the individual amiga folders (see summary folders specifically). Some output will be included in the cdiff-biolog-growth/tables generated by this script. This script will take between 2-3 hours to complete.

8) Generate figures

Generate figures with sh cdiff-biolog-growth/code/generate-figures/driver.sh. All output will be included in the cdiff-biolog-growth/figures generated by this script. This script will take a few minutes to complete.

Citation

Midani, F. S., Danhof, H. A., Mathew, N., Ardis, C. K., Garey, K. W., Spinler, J. K., & Britton, R. A. (2025). Emerging Clostridioides difficile ribotypes have divergent metabolic phenotypes. mSystems. https://doi.org/10.1128/msystems.01075-24

Funding

This research was performed at the Baylor College of Medicine in Houston, Texas, and was supported by several grants from the National Institutes of Health including T32DK007664, F32AI136404, U19AI157981, R01AI123278, and U01AI124290.

About

Code for analyzing data in the C. difficile Biolog manuscript by Midani et al.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published