Skip to contents

align_to_ref() will:

  1. Filter any variants where EffectAllele or OtherAllele is not the reference genome allele

  2. Flip EffectAllele such that it is always the reference genome allele

  3. If OtherAllele is the reference genome allele, direction of B,Z and EAF are flipped.

Usage

align_to_ref(dset, ref = c("REF_38", "REF_37"))

Arguments

dset

object created by arrow::open_dataset() or dplyr::tibble()

ref

Reference genome allele to align to. Varies in ~0.5% of locations

Value

a dplyr::tibble() or arrow query depending on whether dset is a tibble or arrow dataset

Examples

if (FALSE) { # \dontrun{
align_to_ref(tidygwas_df, ref = "REF_38")
} # }