optimize_n: Optimize the n parameter during denovo stacks assembly

Description Usage Arguments Value Examples

View source: R/optimize_n.R

Description

This function requires the path to stacks vcf file(s) as input. There are slots for varying the n parameter across M-1, M, and M-1 (as recommended by Paris et al. 2017). After running stacks with each of the n options, plug the output vcf files into this function to visualize the effect of varying m on number of SNPs and loci built to recognize which value optimizes the n parameter for your dataset at the 'R80' cutoff (Paris et al. 2017).

Usage

1
optimize_n(nequalsMminus1 = NULL, nequalsM = NULL, nequalsMplus1 = NULL)

Arguments

nequalsMminus1

Path to the input vcf file for a run when n=M-1

nequalsM

Path to the input vcf file for a run when n=M

nequalsMplus1

Path to the input vcf file for a run when n=M+1

Value

A dataframe showing the number of SNPs and loci retained across filtering levels for each n value

Examples

1
2
optimize_n(nequalsM =
system.file("extdata","nequalsm.vcf.gz",package="RADstackshelpR",mustWork=TRUE))

RADstackshelpR documentation built on Aug. 19, 2021, 5:06 p.m.