readTagDigger | R Documentation |
readTagDigger
reads the CSV output containing read counts
from TagDigger and generates a "RADdata"
object.
Optionally, it can also import a tag database generated by the
Tag Manager program within TagDigger, containing information
such as alignment position, to be stored in the $locTable
slot of the "RADdata"
object.
readTagDigger(countfile, includeLoci = NULL, possiblePloidies = list(2), taxaPloidy = 2L, contamRate = 0.001, dbfile = NULL, dbColumnsToKeep = NULL, dbChrCol = "Chr", dbPosCol = "Pos", dbNameCol = "Marker name")
countfile |
Name of the file containing read counts. |
includeLoci |
An optional character vector containing names of loci to retain in the output. |
possiblePloidies |
A list of numeric vectors indicating potential inheritance modes of SNPs in the
dataset. See |
taxaPloidy |
A single integer, or an integer vector with one value per taxon, indicating
ploidy. See |
contamRate |
A number ranging from zero to one (typically small) indicating the expected rate of sample cross-contamination. |
dbfile |
Optionally, name of the Tag Manager database file. |
dbColumnsToKeep |
Optionally, a character vector indicating the names of columns to keep from the database file. |
dbChrCol |
The name of the column containing the chromosome number in the database file. |
dbPosCol |
The name of the column indicating alignment position in the database file. |
dbNameCol |
The name of the column containing marker names in the database file. |
Nucleotides associated with the alleles, to be stored in the
$alleleNucleotides
slot, are extracted from the allele names in the
read counts file. It is assumed that the allele names first contain the
marker name, followed by an underscore, followed by the nucleotide(s) at
any variable positions.
A "RADdata"
object.
Lindsay V. Clark
https://github.com/lvclark/tagdigger
Clark, L. V. and Sacks, E. J. (2016) TagDigger: User-friendly extraction of read counts from GBS and RAD-seq data. Source Code for Biology and Medicine 11, 11.
readHMC
, readStacks
, VCF2RADdata
,
readTASSELGBSv2
, readDArTag
# for this example we'll create dummy files countfile <- tempfile() write.csv(data.frame(row.names = c("Sample1", "Sample2", "Sample3"), Mrkr1_A_0 = c(0, 20, 4), Mrkr1_G_1 = c(7, 0, 12)), file = countfile, quote = FALSE) dbfile <- tempfile() write.csv(data.frame(Marker.name = "Mrkr1", Chr = 5, Pos = 66739827), file = dbfile, row.names = FALSE, quote = FALSE) # read the data myrad <- readTagDigger(countfile, dbfile = dbfile)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.