LDproxy_batch: Query LDproxy using a list of query variants, one per line.

View source: R/LDproxy_batch.R

LDproxy_batchR Documentation

Query LDproxy using a list of query variants, one per line.

Description

Query LDproxy using a list of query variants, one per line.

Usage

LDproxy_batch(
  snp,
  pop = "CEU",
  r2d = "r2",
  token = NULL,
  append = FALSE,
  genome_build = "grch37",
  win_size = "500000",
  api_root = "https://ldlink.nih.gov/LDlinkRest"
)

Arguments

snp

a character string or data frame listing rsID's or chromosome coordinates (e.g. "chr7:24966446"), one per line

pop

a 1000 Genomes Project population, (e.g. YRI or CEU), multiple allowed, default = "CEU"

r2d

either "r2" for LD R2 or "d" for LD D', default = "r2"

token

LDlink provided user token, default = NULL, register for token at https://ldlink.nih.gov/?tab=apiaccess

append

A logical. If TRUE, output for each query variant is appended to a text file. If FALSE, output of each query variant is saved in its own text file. Default is FALSE.

genome_build

Choose between one of the three options...'grch37' for genome build GRCh37 (hg19), 'grch38' for GRCh38 (hg38), or 'grch38_high_coverage' for GRCh38 High Coverage (hg38) 1000 Genome Project data sets. Default is GRCh37 (hg19).

win_size

set base pair (bp) window size. Specify a value greater than or equal to zero and less than or equal to 1,000,000bp. Default value is 500,000bp.

api_root

Optional alternative root url for API.

Value

text file(s) are saved to the current working directory.

Examples

## Not run: snps_to_upload <- c("rs3", "rs4")
## Not run: LDproxy_batch(snp = snps_to_upload, token = Sys.getenv("LDLINK_TOKEN"), append = FALSE)


LDlinkR documentation built on May 29, 2024, 4:32 a.m.