Learn R Programming

eDNA_functions

A series of R functions that come in handy while working with metabarcoding data. Made by Ramon Gallego while working at the Kelly Lab (). The reasoning of doing this is to have the same functions we use all the time stored in a curated, reproducible way. In a way it is all about putting together the grammar of the tidyverse with the functions we have used in community ecology.

Copy Link

Version

Install

install.packages('eDNAfuns')

Monthly Downloads

151

Version

0.1.0

License

GPL (>= 3)

Maintainer

Ramón Gallego Simón

Last Published

October 1st, 2025

Functions in eDNAfuns (0.1.0)

template_PCR

template_PCR
test_seqs

test_seqs
write_indexing_PCR

Write Indexing PCR Spreadsheet
training.ASV.table

training.ASV.table
tibble_to_comm

Convert a long tibble to a community matrix
read_info_file

Read cutadapt info files
tally_wide

Create contingency tables with two variables
tree

tree
training.metadata

training.metadata
eDNAindex

Create scaled relative proportions of the number of reads of taxa in different samples
ASV_table

ASV_table
fasta_writer

Read FASTA or FASTQ files into a tibble
fasta_reader

Read FASTA or FASTQ files into a tibble
count_stop_codons

Count stop codons or return translated sequence
read_indexing_PCR

Read Indexing PCR Spreadsheet
tidy2phyloseq

Convert a tidy ASV table to a phyloseq object
mutation

Generate mutated DNA sequences
ng2nM

functions to translate mass into molarity and vice versa, given we are talking about double stranded DNA it requires two inputs, the mass (or molarity) and the length of the DNA fragment It works with the two most common concentrations used in Molecular Ecology labs ng/\(\mu\)l for mass nM for molarity
plot_seq_len_hist

Plot sequence length distribution
molarity.data

molarity.data
AMPURE

AMPURE
Index_PCR

Index_PCR
OTU_taxonomy

OTU_taxonomy
example_hashes

example_hashes
metadata

metadata
UDI_Indices

UDI_Indices
ps

ps