Learn R Programming

Vega (version 1.20.0)

plotSegmentation: Plot observations and the respective segmentation.

Description

This function allows to plot the observed data superimposing the respective segmentation. By the parameter 'opt' he user can plot the LRR mean values of each segment or the computed aberration kind. In plot window the gain and the loss are identified by a line having value of 1 and -1 respectively.

Usage

plotSegmentation(CNVdata, segmentation, chromosomes, opt = 0)

Arguments

CNVdata
The data matrix.
segmentation
The computed segmentation.
chromosomes
The chromosomes that have to be plotted.
opt
If opt=0 (default) then the LRR mean values are plotted, if opt=1 the computed labels are plotted.

References

Morganella S. et al. (2010). VEGA: Variational segmentation for copy number detection, Bioinformatics.

Examples

Run this code
	
	# Import the data
	data(G519)
	
	# Compute the segmentation for all chromosomes
	seg <- vega(G519, c(1:22, "X", "Y"))
	
	# Plot the results for all chromosomes in terms of mean of LRRs 
	plotSegmentation(G519, seg, c(1:22, "X", "Y"), opt=0)

	# Plot the results for all chromosomes in terms of aberration kinds
	plotSegmentation(G519, seg, c(1:22, "X", "Y"), opt=1)
	

Run the code above in your browser using DataLab