Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
35 changes: 14 additions & 21 deletions .Rbuildignore
Original file line number Diff line number Diff line change
@@ -1,24 +1,17 @@
^\.git.*$
^\.github$
^\.build$
^work$
^studies$
^scripts$
^docs$
^AGENTS\.md$
^CODE_OF_CONDUCT\.md$
^LICENSE\.md$
^doc$
^Meta$
^\.github$
(^|/)studies(/|$)
(^|/)scripts(/|$)
(^|/)analysis(/|$)
^Dockerfile$
^\.dockerignore$
^docker$
^apptainer$
^functional-environment\.yml$
^zip-push-gitlfs\.sh$
(^|/)functional(/|$)
^datasetsfromrepo(_validation)?\.RData$
^helperdata/FAPROTAX_1\.2\.12\.zip$
^helperdata/__MACOSX(/|$)
^studies/2024_caenepeel_gastroenterology_IBD_CD_flow/orientation_repair(\.staging)?(/|$)
^studies/2024_caenepeel_gastroenterology_IBD_CD_flow/dada2_output_structure_report\.txt$
^studies/2024_caenepeel_gastroenterology_IBD_CD_flow/inspect_dada2_outputs\.R$
^\.\.Rcheck$
^mutt\.Rcheck$
^mutt_.*\.tar\.gz$
^.*\.Rcheck$
^\.agent-shell$
^\.agents$
^\.codex$
^\.aws$
^plan\.org$
14 changes: 0 additions & 14 deletions .dockerignore

This file was deleted.

15 changes: 4 additions & 11 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,11 +1,4 @@
*.tsv.gz filter=lfs diff=lfs merge=lfs -text
*.txt.gz filter=lfs diff=lfs merge=lfs -text
*.csv.gz filter=lfs diff=lfs merge=lfs -text
*.xlsx.gz filter=lfs diff=lfs merge=lfs -text
*.nwk.gz filter=lfs diff=lfs merge=lfs -text
*.fa.gz filter=lfs diff=lfs merge=lfs -text
*.tar.gz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
studies/**/functional_data/** filter=lfs diff=lfs merge=lfs -text
studies/**/functional_data/*.json -filter -diff -merge text
studies/**/functional_data/**/*.json -filter -diff -merge text
* text=auto
*.R text eol=lf
*.Rmd text eol=lf
*.yml text eol=lf
60 changes: 25 additions & 35 deletions .github/workflows/R-CMD-check.yaml
Original file line number Diff line number Diff line change
@@ -1,47 +1,37 @@
name: R-CMD-check

on:
push:
branches: [ main ]
branches: [main]
pull_request:
branches: [ main ]

branches: [main]
workflow_dispatch:
permissions:
contents: read
concurrency:
group: R-CMD-check-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
R-CMD-check:
name: ${{ matrix.os }} | R ${{ matrix.r }}
runs-on: ${{ matrix.os }}
check:
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
r: release
- os: macOS-latest
r: release
- os: windows-latest
r: release
- os: ubuntu-latest
r: devel

os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
env:
R_KEEP_PKG_SOURCE: yes
_R_CHECK_FORCE_SUGGESTS_: false
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Setup R
uses: r-lib/actions/setup-r@v2
- uses: actions/checkout@v4
with:
r-version: ${{ matrix.r }}

- name: Setup Pandoc
uses: r-lib/actions/setup-pandoc@v2

- name: Install dependencies
uses: r-lib/actions/setup-r-dependencies@v2
lfs: false
- uses: r-lib/actions/setup-r@v2
with:
extra-packages: any::rcmdcheck
needs: check

- name: Run R CMD check
uses: r-lib/actions/check-r-package@v2
use-public-rspm: true
- uses: r-lib/actions/setup-r-dependencies@v2
with:
args: 'c("--no-manual", "--as-cran")'
dependencies: '"hard"'
extra-packages: any::rcmdcheck, any::testthat, any::withr
- name: Check small installed package with local fixtures
shell: Rscript {0}
run: |
rcmdcheck::rcmdcheck(args = c("--no-manual"), error_on = "warning")
44 changes: 0 additions & 44 deletions .github/workflows/docker.yml

This file was deleted.

19 changes: 5 additions & 14 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,9 @@
.RData
.Ruserdata
.DS_Store
/.mutt-r-library/
inst/doc
/doc/
/Meta/
*/functional/
/studies/*/functional/
/..Rcheck/
/mutt.Rcheck/
/.build/
/work/
/*.Rcheck/
/mutt_*.tar.gz
/release/
/datasetsfromrepo*.RData
/helperdata/*.zip
/helperdata/__MACOSX/
*/orientation_repair.staging/
/studies/*/orientation_repair.staging/
/inst/doc/
/..Rcheck/
57 changes: 57 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# Working on *mutt*

*mutt* provides processed microbiome study data from R. Users list studies with
`mutt_studies()` and load the ones they need with `mutt(studies)`.

Write the package name as italic lowercase *mutt* in prose. Keep function names,
paths and other code identifiers unchanged.

## Project layout

- `R/`: installed package code for finding, downloading and loading studies.
- `studies/`: source descriptions and study-specific download and processing scripts.
- `scripts/`: reusable maintenance and release tools.
- `tests/`: small examples for checking package behavior.
- [docs/RELEASING.md](docs/RELEASING.md): instructions for maintaining data releases.

GitHub Releases hold the study ZIPs. `inst/extdata/studies.json` records their
versions, URLs, sizes and checksums. Keep large data outside the active source
tree. Use the ignored `.build/` directory for temporary work and clean it up
when finished.

## Preserve study data

Keep scientific values, names, units, missing values and separate results from
different methods intact. Downloading and packaging must not change counts or
load measurements, or choose a table implicitly.

The default saved study may have different samples in different tables. The
optional `aligned` version follows each study's existing sample-ID matching
rules. Loading reads a saved object; it does not rerun processing or guarantee
that all tables contain the same samples in the same order.

Keep scientific processing study-specific. Shared helpers handle retrieval and
file checks. Describe missing inputs honestly; never invent sources or results.
Preserve original source notes and descriptions of the authors' methods.

## Downloads and releases

Use explicit data versions rather than a moving `latest` URL. Check download
sizes, checksums, archive contents and stored files before use. Extract into a
temporary directory before moving a verified study into the user's saved-data
folder. A failed refresh must leave the previous copy usable.

Release tools package prepared objects without running scientific processing.
Never overwrite published files: corrections require a new data version. Mark
studies available only after publication and successful public-download checks.

## Dependencies and checks

Keep installed dependencies small. Processing dependencies belong in study
scripts. The installed package must work independently of maintenance scripts.
Tests use small local examples; routine CI must not download or rebuild studies.
Functional inference and downstream biological analysis are outside *mutt*'s scope.
Never rewrite Git history as part of cleanup.

Write API help in the roxygen comments in `R/` and regenerate `man/` with
`roxygen2::roxygenise(roclets = "rd")`. Do not edit generated help separately.
58 changes: 13 additions & 45 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,52 +1,20 @@
Package: mutt
Title: A Microbial Scale Repository for Paired Microbiome Sequence Count Data with Total Abundance Measurements
Version: 0.1.0.9000
Authors@R:
c(
person("Maxwell", "Konnaris",
email = "mak6930@psu.edu",
role = c("aut", "cre")),
person("Justin", "Silverman",
email = "JustinSilverman@psu.edu",
role = c("aut", "ctb"))
)
Author: Maxwell Konnaris [aut, cre],
Justin Silverman [aut, ctb]
Maintainer: Maxwell Konnaris <mak6930@psu.edu>
Description: Parses and formats individual studies containing microbiome sequence count data
paired with total abundance measurements (flow cytometry, ddPCR, qPCR, etc.), and returns
a single data object containing selected studies.
Title: Curated Microbiome Taxonomic Profiles and Microbial Load Measurements
Version: 0.1.0.9001
Authors@R: c(person("Maxwell", "Konnaris", email = "mak6930@psu.edu", role = c("aut", "cre")), person("Justin", "Silverman", email = "JustinSilverman@psu.edu", role = c("aut", "ctb")))
Description: Provides processed microbiome study data pairing taxonomic profiles
with microbial-load measurements. Downloads only the studies requested and
saves local copies for later use. Downloads are checked before use. Source
information and links to processing scripts explain how each study was
prepared.
License: MIT + file LICENSE
URL: https://github.com/Silverman-Lab/mutt
BugReports: https://github.com/Silverman-Lab/mutt/issues
Encoding: UTF-8
Roxygen: list(markdown = TRUE)
Imports:
digest,
reticulate (>= 1.24),
optparse,
dplyr,
fs,
jsonlite,
purrr,
readr,
readxl,
stringr,
tibble,
tidyr,
tidyverse,
withr
SystemRequirements:
Python (>= 3.9), PICRUSt2 (optional functional inference),
FAPROTAX 1.2.12 (optional functional inference)
Suggests:
Biostrings,
dada2,
knitr,
matrixStats,
R.utils,
rmarkdown,
testthat (>= 3.0.0)
Depends: R (>= 4.0.0)
Imports: digest, jsonlite
Suggests: testthat (>= 3.0.0), withr, phyloseq,
TreeSummarizedExperiment, S4Vectors
Config/testthat/edition: 3
VignetteBuilder: knitr
Roxygen: list(markdown = TRUE)
Config/roxygen2/version: 8.0.0
21 changes: 0 additions & 21 deletions Dockerfile

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# MIT License

Copyright (c) 2025 totallia authors
Copyright (c) 2025 mutt authors

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
21 changes: 7 additions & 14 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -1,15 +1,8 @@
# Generated by roxygen2: do not edit by hand

S3method(as.data.frame,mutt_picrust_branch)
S3method(print,mutt_result)
export(mutt)
import(dplyr)
import(optparse)
import(reticulate)
import(stringr)
import(tidyr)
import(tidyverse)
importFrom(stats,setNames)
importFrom(utils,read.csv)
importFrom(utils,read.table)
importFrom(utils,unzip)
export(mutt_studies)
export(mutt_source)
export(mutt_recipe)
export(mutt_download_raw)
export(mutt_cache_remove)
export(mutt_as_phyloseq)
export(mutt_as_miaverse)
Loading
Loading