mmstats: Print basic statistics of metagenome data

Description Usage Arguments Details Value Author(s) Examples

View source: R/mmstats.R

Description

Calculates some basic statistics like the N50 length, minimum-, mean-, and maximum scaffold lengths, mean GC content, information about essential genes, and more...

Usage

1
mmstats(mm, original_data = NULL, print = TRUE)

Arguments

mm

(required) A dataframe loaded with mmload.

original_data

If mm is a subset/extraction of another dataframe loaded with mmload, then provide here the original dataframe from which the extraction originates to compare the extraction to the original data, see examples. (Default: NULL)

print

(logical) Whether to print the calculated stats or not. (Default: TRUE)

Details

The returned stats are calculated as follows:

Value

A dataframe with the calculated stats is returned invisibly.

Author(s)

Kasper Skytte Andersen ksa@bio.aau.dk

Soren M. Karst smk@bio.aau.dk

Mads Albertsen MadsAlbertsen85@gmail.com

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
library(mmgenome2)
data(mmgenome2)
mmstats(mmgenome2)

# Compare an extraction with the original data from which the extraction originates:
selection <- data.frame(
  cov_C13.11.25 = c(7.2, 16.2, 25.2, 23.3, 10.1),
  cov_C14.01.09 = c(47, 77, 52.8, 29.5, 22.1)
)
mmgenome2_extraction <- mmextract(mmgenome2,
  selection = selection
)

mmstats(mmgenome2_extraction, original_data = mmgenome2)

KasperSkytte/mmgenome2 documentation built on Dec. 14, 2021, 12:11 a.m.