reformatGenoClasses: Convert genotypes

View source: R/quantgen.R

reformatGenoClassesR Documentation

Convert genotypes

Description

Reformat bi-allelic SNP genotypes encoded in genotypic classes to ease subsequent manipulations.

Usage

reformatGenoClasses(
  file = NULL,
  x = NULL,
  na.string = "--",
  sep = "",
  verbose = 1
)

Arguments

file

the name of the file which the data are to be read from, with a header line, columns separated by a tabulation, and row names as the first column

x

if file=NULL, data.frame of bi-allelic SNP genotypes encoded in genotypic classes, i.e. in AA,AB or BA,BB, with SNPs in rows and genotypes in columns; if it is a matrix, it will be silently transformed into a data frame

na.string

a character to be interpreted as NA values

sep

separator of alleles within each SNP genotype to be removed

verbose

verbosity level (0/1)

Value

matrix with SNPs in rows and genotypes in columns

Author(s)

Eric Duchene [aut], Timothee Flutre [ctb]

See Also

genoClasses2genoDoses, genoClasses2JoinMap


timflutre/rutilstimflutre documentation built on Feb. 7, 2024, 8:17 a.m.