Used internally in radr and might be of interest for users. The function generate a tidy dataset of DArT markers and associated metadata. Usefull to filter before importing the actual dataset.
Usage
tidy_dart_metadata(
data,
filename = NULL,
verbose = FALSE,
parallel.core = parallel::detectCores() - 1
)Arguments
- data
DArT output file. Note that most popular formats used by DArT are recognised (1- and 2- row format, also called binary, and count data.). If you encounter a problem, sent me your data so that I can update the function. The function can import
.csvor.tsvfiles.- filename
(optional) The function uses
read_parquet, to write the tidy data frame in the working directory. The file extension appended to thefilenameprovided is.arrow.parquet. With default:filename = NULL, the tidy data frame is in the global environment only (i.e. not written in the working directory...). Default:filename = NULL.- verbose
Logical indicating whether progress messages are emitted. Default:
verbose = FALSE.- parallel.core
Default:
parallel.core = parallel::detectCores() - 1.
Value
A tidy dataframe with these columns:
MARKERS: generated by radr and correspond to CHROM + LOCUS + POS separated by 2 underscores.
CHROM: the chromosome, for de novo: CHROM_1.
LOCUS: the locus.
POS: the SNP id on the LOCUS.
REF: the reference allele.
ALT: the alternate allele.
CALL_RATE: call rate output specific of DArT.
AVG_COUNT_REF: the coverage for the reference allele, output specific of DArT.
AVG_COUNT_SNP: the coverage for the alternate allele, output specific of DArT.
REP_AVG: the reproducibility average, output specific of DArT.
Author
Thierry Gosselin thierrygosselin@icloud.com
