Initialize a new project database
Usage
new_db(
db_path = "./.sqlite",
mapping_fn = NULL,
mapping_id = "ID",
mapping_taxon = "Taxon",
mapping_geome = "GEOME_BCID",
fetch_geome = TRUE,
mapping_gbif = "GBIF_ID",
fetch_gbif = TRUE,
mapping_ncbi = "BioSample",
fetch_ncbi = TRUE,
link_sources = FALSE,
genetic_code = NULL,
dedup = FALSE,
assemble_cpus = 6,
assemble_memory = 24,
assembler = "GetOrganelle",
seeds_db =
"https://raw.githubusercontent.com/smithsonian/MitoPilot/main/ref_dbs/getOrganelle/seeds/fish_mito_seeds.fasta",
labels_db =
"https://raw.githubusercontent.com/smithsonian/MitoPilot/main/ref_dbs/getOrganelle/labels/fish_mito_labels.fasta",
getOrganelle = paste("-F 'anonym'", "-R 10 -k '21,45,65,85,105,115'",
"--larger-auto-ws", "--expected-max-size 20000", "--target-genome-size 16500"),
mitofinder_db =
"https://raw.githubusercontent.com/Smithsonian/MitoPilot/refs/heads/main/ref_dbs/MitoFinder/fish_mito_sampler.gb",
mitofinder = paste("--megahit"),
maptoref_mapper = "bowtie2",
maptoref = .mtr_default_bowtie2,
maptoref_consensus = .mtr_default_consensus,
maptoref_iter = 5L,
max_paths = 10,
max_scaffolds = 10,
min_assembly_length = 500,
annotate_cpus = 6,
annotate_memory = 36,
annotate_ref_db = "Chordata",
annotate_ref_dir =
"https://raw.githubusercontent.com/Smithsonian/MitoPilot/refs/heads/main/ref_dbs/Mitos2",
mitos_opts = "--intron 0 --oril 0",
trnaScan_opts = "-M vert -X 20",
arwen_opts = "-mtx",
aragorn_opts = "-m -gcstd",
curate_cpus = 4,
curate_memory = 8,
curate_target = "fish_mito",
curate_ref_db = "Metazoa_RefSeq235",
max_blast_hits = 10,
linear_complete = FALSE,
curate_params = NULL,
orf_cpus = 4,
orf_memory = 8,
orffinder_opts = "-s 1",
orf_min_len = 300,
orf_max_overlap = 0.1
)Arguments
- db_path
Path to the new database file
- mapping_fn
Path to the mapping CSV file. Must contain columns "ID", "Taxon, "R1", and "R2"
- mapping_id
Column name of the mapping file to use as the primary key
- mapping_taxon
Column name of the mapping file containing a Taxonomic identifier (eg, species name)
- mapping_geome
Name of the mapping-file column holding GEOME BCIDs (optional). Stored as `GEOME_BCID`. See `vignette("Specimen-Metadata")`.
- fetch_geome
Fetch GEOME metadata for samples with a BCID during setup (default TRUE). Set FALSE when offline and run [fetch_geome()] later.
- mapping_gbif
Name of the mapping-file column holding GBIF occurrence IDs (optional). Stored as `GBIF_ID`. See `vignette("Specimen-Metadata")`.
- fetch_gbif
Fetch GBIF metadata for samples with a GBIF ID during setup (default TRUE). Set FALSE when offline and run [fetch_gbif()] later.
- mapping_ncbi
Name of the mapping-file column holding NCBI BioSample or SRA accessions (optional). Must not be the sample ID column. Stored as `BioSample`. See `vignette("Specimen-Metadata")`.
- fetch_ncbi
Fetch NCBI metadata for samples with a BioSample value during setup (default TRUE). Set FALSE when offline and run [fetch_ncbi()] later.
- link_sources
Follow links between GEOME, GBIF, and NCBI records to fill in IDs a sample does not have yet (default FALSE). Saved as the project setting. See `vignette("Specimen-Metadata")`.
- genetic_code
Optional NCBI translation table override. Default `NULL` auto-selects from the curation ruleset (`curate_target`); a number sets an override on the default curate_opts set. https://www.ncbi.nlm.nih.gov/Taxonomy/Utils/wprintgc.cgi
- dedup
Run fastp with `–dedup` to drop PCR and optical duplicates before assembly? Default FALSE keeps `–dont_eval_duplication`, the shipped fastp default. Editable later in the preprocess-options modal.
- assemble_cpus
Default # cpus for assembly
- assemble_memory
default memory (GB) for assembly
- assembler
Assembler, choice of "GetOrganelle" (default), "MitoFinder", or "MapToRef"
- seeds_db
Path to the gotOrganelle seeds database, can be a URL, cannot have same file name as labels_db. Default is a fish database built from RefSeq. https://raw.githubusercontent.com/smithsonian/MitoPilot/main/ref_dbs/getOrganelle/seeds/fish_mito_seeds.fasta
- labels_db
Path to the gotOrganelle labels database, can be a URL, cannot have same file name as seeds_db. Default is a fish database built from RefSeq. https://raw.githubusercontent.com/smithsonian/MitoPilot/main/ref_dbs/getOrganelle/seeds/fish_mito_labels.fasta
- getOrganelle
Default getOrganelle command line options
- mitofinder_db
Path to MitoFinder reference db, must be GenBank format (.gb), can be a URL. Default is a ten-species fish mitogenome sampler (https://raw.githubusercontent.com/Smithsonian/MitoPilot/refs/heads/main/ref_dbs/MitoFinder/fish_mito_sampler.gb)
- mitofinder
Default MitoFinder command line options
- maptoref_mapper
MapToRef read mapper, "bowtie2", "bwa-mem", or "bwa-aln" (default = "bowtie2")
- maptoref
Default mapper options for MapToRef (default = "–very-sensitive-local")
- maptoref_consensus
Default samtools consensus options for MapToRef (default = "-d 3 –min-BQ 20")
- maptoref_iter
Maximum MapToRef iteration passes (default = 5)
- max_paths
Maximum number of assembly paths allowed for a sample to continue past the Assemble step (default = 10). Samples exceeding this are flagged as failed and skipped by downstream steps in WF1.
- max_scaffolds
Maximum number of scaffolds (within a single path) allowed for a sample to continue past the Assemble step (default = 10). Samples exceeding this are flagged as failed and skipped by downstream steps in WF1.
- min_assembly_length
Minimum contig length (bp) to retain for coverage calculations, BLAST, and annotation. Scaffolds shorter than this threshold are stored but flagged as ignored (default = 500).
- annotate_cpus
Default # cpus for annotation
- annotate_memory
Default memory (GB) for annotation
- annotate_ref_db
Default Mitos2 reference database
- annotate_ref_dir
Default Mitos2 reference database directory
- mitos_opts
Default MITOS2 command line options
- trnaScan_opts
Default tRNAscan-SE command line options
- arwen_opts
Default ARWEN command line options
- aragorn_opts
Default ARAGORN command line options
- curate_cpus
Default # cpus for curation
- curate_memory
Default memory (GB) for curation
- curate_target
Default target database for curation
- curate_ref_db
Default curation reference database (default = "Metazoa_RefSeq235", the only bundled DB with rRNA BLAST references)
- max_blast_hits
Maximum number of top BLAST hits to retain (default = 10)
- linear_complete
Treat linear assemblies as complete genomes for the export "completeness" field? By default only circular assemblies are labeled "complete genome" and linear assemblies "partial genome". Set TRUE for taxa whose complete mitogenome is genuinely linear (default = FALSE). Editable later in the curation-options modal.
- curate_params
Default curation parameters
- orf_cpus
CPUs for the optional ORF-finder step (default = 4)
- orf_memory
Memory (GB) for the optional ORF-finder step (default = 8)
- orffinder_opts
Default NCBI ORFfinder options (default = "-s 1")
- orf_min_len
Minimal ORF length in nucleotides (default = 300)
- orf_max_overlap
Maximum overlap with existing annotations, as a fraction of the ORF length, before an ORF is discarded (default = 0.1)
