Learn R Programming

bigsnpr (version 1.6.1)

snp_asGeneticPos: Interpolate to genetic positions

Description

Use genetic maps available at https://github.com/joepickrell/1000-genomes-genetic-maps/ to interpolate physical positions (in bp) to genetic positions (in cM).

Usage

snp_asGeneticPos(infos.chr, infos.pos, dir = tempdir(), ncores = 1)

Arguments

infos.chr

Vector of integers specifying each SNP's chromosome. Typically <bigSNP>$map$chromosome.

infos.pos

Vector of integers specifying the physical position on a chromosome (in base pairs) of each SNP. Typically <bigSNP>$map$physical.pos.

dir

Directory where to download and decompress files. Default is tempdir(). Directly use files there if already present.

ncores

Number of cores used. Default doesn't use parallelism. You may use nb_cores.

Value

The new vector of genetic positions.