ReadAndSplitMutectVCFs: Read and split Mutect VCF files

View source: R/shiny_related_functions.R

ReadAndSplitMutectVCFsR Documentation

Read and split Mutect VCF files

Description

Read and split Mutect VCF files

Usage

ReadAndSplitMutectVCFs(
  files,
  names.of.VCFs = NULL,
  tumor.col.names = NA,
  suppress.discarded.variants.warnings = TRUE
)

Arguments

files

Character vector of file paths to the Mutect VCF files.

names.of.VCFs

Optional. Character vector of names of the VCF files. The order of names in names.of.VCFs should match the order of VCF file paths in files. If NULL(default), this function will remove all of the path up to and including the last path separator (if any) in files and file paths without extensions (and the leading dot) will be used as the names of the VCF files.

tumor.col.names

Optional. Character vector of column names in VCFs which contain the tumor sample information. The order of names in tumor.col.names should match the order of VCFs specified in files. If tumor.col.names is equal to NA(default), this function will use the 10th column in all the VCFs to calculate VAFs. See GetMutectVAF for more details.

suppress.discarded.variants.warnings

Logical. Whether to suppress warning messages showing information about the discarded variants. Default is TRUE.

Value

A list containing the following objects:

  • SBS: List of VCFs with only single base substitutions.

  • DBS: List of VCFs with only doublet base substitutions as called by Mutect.

  • ID: List of VCFs with only small insertions and deletions.

  • 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.

See Also

MutectVCFFilesToCatalog

Examples

file <- c(system.file("extdata/Mutect-vcf",
                      "Mutect.GRCh37.s1.vcf",
                      package = "ICAMS"))
list.of.vcfs <- ReadAndSplitMutectVCFs(file)

ICAMS documentation built on June 22, 2024, 6:47 p.m.