phaseHETinversion: Phase a heterozygous inversion using Strand-seq data

View source: R/correctInversionPhasing.R

phaseHETinversionR Documentation

Phase a heterozygous inversion using Strand-seq data

Description

This function takes as an input region deemed to be a heterozygous inversion and attempts to phase SNVs inside this region using haplotype informative Strand-seq reads from multiple single cells.

Usage

phaseHETinversion(
  input.bams = NULL,
  snv.positions = NULL,
  phase.gr = NULL,
  lookup.bp = 1e+06,
  lookup.blacklist = NULL,
  pairedEndReads = TRUE,
  min.mapq = 10,
  bsGenome = NULL,
  ref.fasta = NULL,
  assume.biallelic = TRUE,
  verbose = FALSE
)

Arguments

input.bams

A path to a VCF file to be loaded.

snv.positions

A path to a VCF files containing SNV positions to phase.

phase.gr

A GRanges object containing a single region to be phased. This region should point to a heterozygous inversion site.

lookup.bp

A number of nucleotides, downstream and upstream, from the heterozygous inversion site ('phase.gr') to be genotyped.

lookup.blacklist

A GRanges object or a path to a BED file containing a set of ranges to be excluded when extending 'phase.gr' by 'lookup.bp'. The total size of 'lookup.bp' is kept after filtering.

pairedEndReads

Set to TRUE if you have paired-end reads in your file.

min.mapq

Minimum mapping quality when importing from BAM files.

bsGenome

A BSgenome object which contains reference genome used to infer reference alleles.

ref.fasta

A user defined reference FASTA file to extract reference allele for all SNV positions.

assume.biallelic

If set to TRUE parameter 'snv.positions' is expected to contain biallelic loci (0/1, 1/0) and thus gaps in haplotypes will be filled accordingly.

verbose

Is set to TRUE function will provide a more detailed messaging of ongoing analysis steps.

Value

A data.frame with phased alleles per inverted and reference haplotype.

Author(s)

David Porubsky


daewoooo/StrandPhaseR documentation built on April 7, 2024, 7:13 p.m.