read_eigenstrat: Read genotype data from _EIGENSTRAT_ files

View source: R/io.R

read_eigenstratR Documentation

Read genotype data from EIGENSTRAT files

Description

Read genotype data from EIGENSTRAT files

Usage

read_eigenstrat(
  pref,
  inds = NULL,
  pops = NULL,
  first = 1,
  last = Inf,
  transpose = FALSE,
  verbose = TRUE
)

Arguments

pref

Prefix of the packedancestrymap files

inds

Individuals for which data should be read. Defaults to all individuals

pops

Populations for which data should be read. Cannot be provided together with 'inds'

first

Index of first SNP to read

last

Index of last SNP to read

transpose

Transpose genotype matrix (default is snps x individuals)

verbose

Print progress updates

Value

A list with the genotype data matrix, the .ind file, and the .snp file

Examples

## Not run: 
samples = c('Ind1', 'Ind2', 'Ind3')
geno = read_packedancestrymap(prefix, samples)

## End(Not run)

uqrmaie1/admixtools documentation built on Nov. 3, 2024, 12:56 a.m.