capellini.stages.dada2
DADA2 stage: run DADA2_Pipe.R and move the generated FASTA.
Functions
|
Run the DADA2_Pipe.R script and move the output FASTA to the input folder. |
- capellini.stages.dada2.run_dada2(cfg: CapelliniConfig) Path[source]
Run the DADA2_Pipe.R script and move the output FASTA to the input folder.
- The R script is called with six arguments matching the notebook:
- Rscript DADA2_Pipe.R <bacterial_raw_fasta_folder> <dada2_folder>
<silva_ref_path> <silva_taxmap_path> <direction> <TRUE|FALSE>
After the run the produced ASV_sequences_{F|R|P}.fasta is moved to
cfg.input_fasta_folder / cfg.bacteria_fasta_name.- Parameters:
cfg – Populated CapelliniConfig instance.
- Returns:
Path to the moved bacteria FASTA file.
- Raises:
FileNotFoundError – If the FASTA is not found after the R run.
subprocess.CalledProcessError – If Rscript exits non-zero.