create_plink_bin_data: Create a set of 'PLINK' binary data

View source: R/create_plink_bin_data.R

create_plink_bin_dataR Documentation

Description

Create a set of PLINK binary data

Usage

create_plink_bin_data(bim_table, fam_table, bed_table)

Arguments

bim_table

a tibble of the genetic mapping, with as many rows as SNPs.

Each row contains:

  • chr: the chromosome number

  • id: the SNP ID

  • posg: the position

  • pos: the position

  • ref: something

  • alt: something

Use get_test_bim_table to get a .bim table as used in testing. Use read_plink_bim_file to read a PLINK .bim file. Use check_bim_table to test if a .bim table is valid.

fam_table

a tibble of the genetic mapping, with as many rows as SNPs.

Each row contains:

  • fam: the family ID

  • id: the individual's ID

  • pat: ID of father

  • mat: ID of mother

  • sex: the gender

  • pheno: a phenotype

Use get_test_fam_table to get a .fam table as used in testing. Use read_plink_fam_file to read a PLINK .fam file. Use check_fam_table to test if a .fam table is valid.

bed_table

a table that maps the SNPs to the individuals, of which the column names are the names of the individuals, the row names are the names of the SNPs, and the values are the SNP variant. Use get_test_bed_table to get a .bed table as used in testing. Use read_plink_bed_file to read a PLINK .bed file. Use check_bed_table to test if a .bed table is valid. See also the bed file format reference at https://www.cog-genomics.org/plink2/formats#bed

Author(s)

Richèl J.C. Bilderbeek

See Also

use create_test_plink_bin_data to create a set of PLINK binary data to be used in testing

Examples

create_plink_bin_data(
  bim_table = get_test_bim_table(),
  fam_table = get_test_fam_table(),
  bed_table = get_test_bed_table()
)

richelbilderbeek/plinkr documentation built on March 25, 2024, 3:18 p.m.