get_overlap_seg_with_mask_ind: Find Overlapping Segments with a CNV Mask

Description Usage Arguments Value Examples

Description

Given a TitanCNA segment data.frame and a mask segment data.frame, this function will find whether any TitanCNA segment overlaps, with any significant degree according to the overlap.prop parameter, with a CNV mask segment. It returns the row number of any segment that does.

Usage

1
get_overlap_seg_with_mask_ind(segs.df, mask.df, overlap.prop = 0.25)

Arguments

segs.df

TitanCNA segments in a data.frame. This can be the data.frame loaded from the load_titan_seg function. Or at the very least the data.frame should contain the columns: Chromosome, Start_Position, End_Position

mask.df

Mask segment in a data.frame. Must contain the columns: chr, start, end

overlap.prop

Proportion that the TitanCNA segment must overlap with cnv mask segment in order to be considered overlapping

Value

Vector containing the row number in the segs.df that overlaps with any cnv.mask segment

Examples

1
2
3
4
5
6
segs.df <- data.frame(chr = c("chr1", "chr2", "chr1", "chr3"),
                      start = 1:4, end = 7:10,
                      stringsAsFactors = FALSE)
mask.df <- data.frame(chr = "chr1", start = 6, end = 8,
                          stringsAsFactors = FALSE)
get_overlap_seg_with_mask_ind(segs.df, mask.df)

tinyheero/titanCNAutils documentation built on May 31, 2019, 3:37 p.m.