confidenceInterval.binomial: Estimate confidence intervals for breakpoints

View source: R/confidenceInterval.R

confidenceInterval.binomialR Documentation

Estimate confidence intervals for breakpoints

Description

Estimate confidence intervals for breakpoints by going outwards from the breakpoint read by read, and performing a binomial test of getting the observed or a more extreme outcome, given that the reads within the confidence interval belong to the other side of the breakpoint.

Usage

confidenceInterval.binomial(breaks, fragments, background = 0.02, conf = 0.99)

Arguments

breaks

Genotyped breakpoints as outputted from function GenotypeBreaks.

fragments

Read fragments from function readBamFileAsGRanges.

background

The percent (e.g. 0.05 = 5%) of background reads allowed for WW or CC genotype calls.

conf

Desired confidence interval of localized breakpoints.

Value

A GRanges-class object of breakpoint ranges for a given confidence interval in conf.

Author(s)

Aaron Taudt, David Porubsky

Examples

## Not run:  
## Get an example file 
exampleFolder <- system.file("extdata", "example_results", package="breakpointRdata")
exampleFile <- list.files(exampleFolder, full.names=TRUE)[1]
## Load the file 
breakpoint.objects <- get(load(exampleFile))
## Calculate confidence intervals of genotyped breakpoints
confint <- confidenceInterval.binomial(breakpoint.objects$breaks, breakpoint.objects$fragments, background=0.02)
## End(Not run)


daewoooo/BreakPointR documentation built on May 8, 2024, 10:43 p.m.