loadCopyNumberCallsSeg: loadCopyNumberCallsSeg

Description Usage Arguments Details Value Examples

View source: R/loadCopyNumberCallsSeg.R

Description

Loads copy number calls from .seg file format

Usage

1
loadCopyNumberCallsSeg (seg.file, chr.col = "chrom", start.col = "loc.start", end.col = "loc.end", segment.value.col = "seg.mean", cn.col = NULL, genome = NULL, chr.transformation = "23:X,24:Y,25:MT", verbose = TRUE)

Arguments

seg.file

The name of the file with the data

chr.col

(number or character) The name or number of the column with chromosome information. If NULL, it is automatically identified. (defaults to "chrom")

start.col

(number or character) The name or number of the column with start position information. If NULL, it is automatically identified. (defaults to "loc.start")

end.col

(number or character) The name or number of the column with end position information. If NULL, it is automatically identified. (defaults to "loc.end")

segment.value.col

(number or character) The name or number of the column with segment value. If NULL, it is automatically identified. (defaults to "seg.mean")

cn.col

(number or character)The name or number of the column with CN information. If NULL, it is automatically identified. (defaults to NULL)

genome

(character) The name of the genome (defaults to NULL)

chr.transformation

(character)(character) The transformation of the chromosome names in a comma separated "key:value" format as detailed at https://cnvkit.readthedocs.io/en/stable/importexport.html#import-seg.(defaults to "23:X,24:Y,25:MT")

verbose

(logical) Whether to show information messages. (defaults to TRUE)

Details

This function will load segments data from .seg file format. Internally it uses the toGRanges function from regioneR package and can work with any format accepted by it, including R objects and local or remote files. If no column names are specified, it will use simple heuristics to try to identify the relevant data columns.

Value

A GRanges with a range per copy number segment

Examples

1
2
3
4
5
6
7
## loadCopyNumberCallsSeg from .seg file format: 
## the file to run in the example can be found in:
## https://software.broadinstitute.org/software/igv/SEG
## under example.seg file name.

seg.file <- system.file("extdata", "DNACopy_output.seg", package = "CopyNumberPlots", mustWork = TRUE)
cnv.call <- loadCopyNumberCallsSeg(seg.file = seg.file)

CopyNumberPlots documentation built on Nov. 8, 2020, 6:51 p.m.