View source: R/shiny_related_functions.R
VCFsToSBSCatalogs | R Documentation |
Create a list of 3 catalogs (one each for 96, 192, 1536) out of the contents in list.of.SBS.vcfs. The SBS VCFs must not contain DBSs, indels, or other types of mutations.
VCFsToSBSCatalogs(
list.of.SBS.vcfs,
ref.genome,
num.of.cores = 1,
trans.ranges = NULL,
region = "unknown",
return.annotated.vcfs = FALSE,
suppress.discarded.variants.warnings = TRUE
)
list.of.SBS.vcfs |
List of in-memory data frames of pure SBS mutations – no DBS or 3+BS mutations. The list names will be the sample ids in the output catalog. |
ref.genome |
A |
num.of.cores |
The number of cores to use. Not available on Windows
unless |
trans.ranges |
Optional. If
then the function will infer |
region |
A character string designating a genomic region;
see |
return.annotated.vcfs |
Logical. Whether to return the annotated VCFs with additional columns showing mutation class for each variant. Default is FALSE. |
suppress.discarded.variants.warnings |
Logical. Whether to suppress warning messages showing information about the discarded variants. Default is TRUE. |
A list containing the following objects:
catSBS96
, catSBS192
, catSBS1536
: Matrix of
3 SBS catalogs (one each for 96, 192, and 1536).
discarded.variants
: Non-NULL only if there are variants
that were excluded from the analysis. See the added extra column
discarded.reason
for more details.
annotated.vcfs
:
Non-NULL only if return.annotated.vcfs
= TRUE.
SBS VCF annotated by AnnotateSBSVCF
with
three new columns SBS96.class
, SBS192.class
and
SBS1536.class
showing the mutation class for each SBS variant.
If trans.ranges
is not provided by user and cannot be inferred by
ICAMS, SBS 192 catalog will not be generated. Each catalog has attributes
added. See as.catalog
for more details.
To add or change attributes of the catalog, you can use function
attr
.
For example, attr(catalog, "abundance")
<- custom.abundance
.
SBS 192 catalogs only contain mutations in transcribed regions.
file <- c(system.file("extdata/Mutect-vcf",
"Mutect.GRCh37.s1.vcf",
package = "ICAMS"))
list.of.SBS.vcfs <- ReadAndSplitMutectVCFs(file)$SBS
if (requireNamespace("BSgenome.Hsapiens.1000genomes.hs37d5", quietly = TRUE)) {
catalogs.SBS <- VCFsToSBSCatalogs(list.of.SBS.vcfs, ref.genome = "hg19",
trans.ranges = trans.ranges.GRCh37,
region = "genome")}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.