hasPartner: Determines whether this breakend has a valid partner in this...

Description Usage Arguments Value Examples

View source: R/BreakpointGRanges.R

Description

Determines whether this breakend has a valid partner in this GRanges

Usage

1
hasPartner(gr, selfPartnerSingleBreakends = FALSE)

Arguments

gr

GRanges object of SV breakends

selfPartnerSingleBreakends

treat single breakends as their own partner.

Value

True/False for each row in the breakpoint GRanges

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
#Subset to chromosome 6 intra-chromosomal events \code{vcf}
vcf.file <- system.file("extdata", "COLO829T.purple.sv.ann.vcf.gz",
  package = "StructuralVariantAnnotation")
vcf <- VariantAnnotation::readVcf(vcf.file)
gr <- breakpointRanges(vcf)
gr <- gr[seqnames(gr) == "6"]
# We now need to filter out inter-chromosomal events to ensure
# our GRanges doesn't contain any breakpoints whose partner
# has already been filtered out and no longer exists in the GRanges.
gr <- gr[hasPartner(gr)]

d-cameron/StructuralVariantAnnotation documentation built on Dec. 26, 2021, 6:14 p.m.