correctInvertedRegionPhasing: Correct StrandPhaseR phasing over inverted regions

View source: R/correctInversionPhasing.R

correctInvertedRegionPhasingR Documentation

Correct StrandPhaseR phasing over inverted regions

Description

This function attempts to correct phasing over inverted regions using both breakpointR and StrandPhaseR results.

Usage

correctInvertedRegionPhasing(
  input.bams,
  outputfolder = NULL,
  inv.bed = NULL,
  recall.phased = FALSE,
  het.genotype = "strict",
  chromosomes = NULL,
  snv.positions = NULL,
  composite.file = NULL,
  breakpointR.data = NULL,
  strandphaseR.data = NULL,
  pairedEndReads = TRUE,
  min.mapq = 10,
  background = 0.05,
  vcfs.files = NULL,
  lookup.bp = 1e+06,
  lookup.blacklist = NULL,
  bsGenome = NULL,
  ref.fasta = NULL,
  assume.biallelic = TRUE,
  overwrite.results = TRUE
)

Arguments

input.bams

A path to a VCF file to be loaded.

outputfolder

A path to a folder where all summary and intermediate results will be stored.

inv.bed

A BED formatted file that contains likely inverted regions to evaluate.

recall.phased

If set to TRUE,inversion signatures will be re-called using phased Strand-seq reads (Useful to redefine HET inversion boundaries).

het.genotype

If set to 'strict' heterozygous inversion has to be supported by both 'breakpointR.data' and 'strandphaseR.data', if set to 'lenient' support from either 'breakpointR.data' only is sufficient.

chromosomes

Limit analysis to a certain chromosomes only.

snv.positions

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

composite.file

...

breakpointR.data

A path to results obtained by running breakpointR package on a given sample.

strandphaseR.data

A path to results obtained by running StrandPhaseR package on a given sample.

pairedEndReads

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

min.mapq

Minimum mapping quality when importing from BAM files.

vcfs.files

A path to a folder where all VCF files to be corrected are stored (sample specific).

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.

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.

overwrite.results

Set to FALSE if existing corrected VCF files should be used instead of creating a new copy of original VCF file.

Value

NULL or data.frame depending if 'outputfolder' is defined.

Author(s)

David Porubsky


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