read_reference_bed: Read a PLINK bed file for reference data

View source: R/read_reference_bed.R

read_reference_bedR Documentation

Read a PLINK bed file for reference data

Description

Create a bed.matrix object from a .bed file. The function expects .fam and .bim files under the same directory. See gaston::read.bed.matrix for more details.

Usage

read_reference_bed(path, ...)

Arguments

path

A path to the .bed file

...

Further arguments used in gaston::read.bed.matrix

Value

A gaston::bed.matrix object with a Z-standardized genotype matrix

Examples

## Get a path to the example .bed file
bfile <- system.file("extdata", "example.bed", package = "snpsettest")

## Read a .bed file
x <- read_reference_bed(path = bfile)

snpsettest documentation built on Sept. 10, 2023, 1:08 a.m.