| read.plink.binary {rres} | R Documentation |
Read PLINK binary file.
Description
read.plink.binary reads PLINK binary .bed file and the corresponding .bim and .fam file.
Usage
read.plink.binary(bed, bim = NULL, fam = NULL, na.strings = c("0", "-9"))
Arguments
bed, bim, fam |
PLINK files with appropriate extensions. |
na.strings |
string vector, text entries to be treated as NA's. |
Details
When the three files have the same name, only the .bed file needs to be specified.
Value
A list of three elements: genotype, fam and map.
To be consistent with PLINK .bed file, genotype is a n_subject by n_marker matrix of counts of reference alleles. 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.
[Package rres version 1.1 Index]