plotBestNormal {PureCN} | R Documentation |
This function can be used to understand how a best normal is chosen by the
findBestNormal
function. It can be also used to tune the best
normal selection by finding good parameter values for num.normals
and
pcs
.
plotBestNormal(normal.coverage.files, tumor.coverage.file, normalDB, x = 1, y = 2, col.tumor = "red", col.best.normal = "blue", col.other.normals = "black", ...)
normal.coverage.files |
Coverage file names of normal samples,
typically identified via |
tumor.coverage.file |
Coverage file or data of a tumor sample. |
normalDB |
Database of normal samples, created with
|
x |
Principal component (PC) to be plotted on x-axis. |
y |
PC to be plotted on y-axis. |
col.tumor |
Color of tumor in plot. |
col.best.normal |
Color of best normals in plot. |
col.other.normals |
Color of other normals in plot. |
... |
Arguments passed to the |
Returns NULL
.
Markus Riester
createNormalDatabase findBestNormal
normal.coverage.file <- system.file("extdata", "example_normal.txt", package="PureCN") normal2.coverage.file <- system.file("extdata", "example_normal2.txt", package="PureCN") normal.coverage.files <- c(normal.coverage.file, normal2.coverage.file) normalDB <- createNormalDatabase(normal.coverage.files) tumor.coverage.file <- system.file("extdata", "example_tumor.txt", package="PureCN") best.normal.coverage.file <- findBestNormal(tumor.coverage.file, normalDB) plotBestNormal(best.normal.coverage.file, tumor.coverage.file, normalDB) # Display sample sex. The first point in the plot is always tumor. plotBestNormal(best.normal.coverage.file, tumor.coverage.file, normalDB, pch=c(1,ifelse(normalDB$sex=="F", 1, 2)))