Transfer genomic coordinates from one genome build to another.

liftover(
  dat,
  chrom_col = "CHR",
  start_col = "POS",
  end_col = start_col,
  build_conversion = c("hg38ToHg19", "hg19ToHg38"),
  as_granges = FALSE,
  verbose = TRUE
)

Arguments

dat

SNP-level data table.

chrom_col

Name of the chromosome column.

start_col

Name of the start position column.

end_col

Name of the end position column (can be same as start_col if all data is SNP-level).

build_conversion

From which to which genome build to lift over dat.

as_granges

Return lifted dat as GenomicRanges object.

verbose

Print messages.

Source

liftOver

UCSC chain files

Examples

data("BST1") dat_lifted <- liftover(dat = BST1, build_conversion = "hg19ToHg38")
#> Lifting genome build: hg19ToHg38
#> Downloading chain file from UCSC Genome Browser.