Description Usage Arguments Details Value
read.plink.text
reads PLINK text files in either the original or transposed format.
1 2 | read.plink.text(ped, map = NULL, output.allele = TRUE, na.strings = c("0",
"-9"))
|
ped, map |
PLINK files with appropraite extensions. |
output.allele |
logical, default is to output genotype as alleles. |
na.strings |
Character vector, set of characters to be treated as missing values. |
The PLINK pedigree file should be supplied with the appropriate extension. The corresponding map file can be omitted if it has the same file name as the pedigree file and has the appropriate extension.
A list of three elements: genotype
, fam
and map
.
To be consistent with PLINK .ped file, genotype
by default is a n_subject by (2 x n_marker) matrix of alleles, where 1 represents the reference allele and 2 the alternate allele. Alternatively, genotype can be outputted as 0, 1 or 2 copies of reference allele count by using output.allele = FALSE
. Missing values are -9.
fam
is a dataframe that contains the first six columns of a PLINK .ped
file.
map
is a dataframe that contains the four columns of a PLINK .map
file, with two additional columns: allele_1
for the reference allele type, allele_2
for the alternate allele type.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.