Learn R Programming

PMA (version 1.0.4)

PlotCGH: Plot CGH data

Description

Given a vector of gains/losses at CGH spots, this makes a plot of gain/loss on each chromosome.

Usage

PlotCGH(array,chrom=NULL,nuc=NULL,main="",scaleEachChrom=TRUE)

Arguments

array
A vector containing the chromosomal location of each CGH spot.
chrom
A numeric vector of the same length as "array"; its values should indicate the chromosome that each CGH spot is on (for instance, for human genomic data, values of chrom should range from 1 to 24). If NULL, then it is assumed that all elements
nuc
A numeric vector of same length as "array", indicating the nucleotide position of each CGH spot. If NULL, then the function assumes that each CGH spot corresponds to a consecutive position. E.g. if there are 200 CGH spots on chromosome 1, then th
main
Give your plot a title.
scaleEachChrom
Default is TRUE. This means that each chromosomes CGH spots are divided by 1.1 times the max of the CGH spots on that chromosome. This way, the CGH spots on each chromosome of the plot are as big as possible (i.e. easy to see). If FALSE, then all of th

Details

This function makes a plot of regions of genomic gain/loss.

References

Witten DM, Tibshirani R and T Hastie (2008) A penalized matrix decomposition with applications to sparse principal components and canonical correlation analysis. Submitted.

See Also

PMD, PMD.cv, CCA, CCA.permute

Examples

Run this code
# Use breast data
data(breastdata)
attach(breastdata)

# dna contains CGH data and chrom contains chromosome of each CGH spot;
# nuc contains position of each CGH spot.
dna <- t(dna)
PlotCGH(dna[1,],chrom=chrom,nuc=nuc,main="Sample 1: All Chromosomes")
PlotCGH(dna[1,chrom==1], chrom=chrom[chrom==1], nuc=nuc[chrom==1],
main= "Sample 1: Chrom 1")
PlotCGH(dna[1,chrom<=3], chrom=chrom[chrom<=3], nuc=nuc[chrom<=3],
 main="Sample 1: Chroms 1, 2, and 3")
detach(breastdata)

Run the code above in your browser using DataLab