plotScoringModel: plotVariantsForCNV

View source: R/plotScoringModel.R

plotScoringModelR Documentation

plotVariantsForCNV

Description

Plots scoring model used for CNV duplications

Usage

plotScoringModel(
  expected.ht.mean,
  expected.dup.ht.mean1,
  expected.dup.ht.mean2,
  sigmoid.c1,
  sigmoid.c2.vector
)

Arguments

expected.ht.mean

Expected heterozygous SNV/indel allele frequency

expected.dup.ht.mean1

Expected heterozygous SNV/indel allele frequency when the variant IS NOT in the same allele than the CNV duplication call

expected.dup.ht.mean2

Expected heterozygous SNV/indel allele frequency when the variant IS in the same allele than the CNV duplication call

sigmoid.c1

Sigmoid c1 parameter

sigmoid.c2.vector

Vector containing sigmoid c2 parameters for the six sigmoids functions

Value

nothing

Examples

# Load CNVs data
cnvs.file <- system.file("extdata", "DECoN.CNVcalls.csv", package = "CNVfilteR", mustWork = TRUE)
cnvs.gr <- loadCNVcalls(cnvs.file = cnvs.file, chr.column = "Chromosome", start.column = "Start", end.column = "End", cnv.column = "CNV.type", sample.column = "Sample")

# Load VCFs data
vcf.files <- c(system.file("extdata", "variants.sample1.vcf.gz", package = "CNVfilteR", mustWork = TRUE),
               system.file("extdata", "variants.sample2.vcf.gz", package = "CNVfilteR", mustWork = TRUE))
vcfs <- loadVCFs(vcf.files, cnvs.gr = cnvs.gr)

# Filter CNVs
results <- filterCNVs(cnvs.gr, vcfs)

# Plot scoring model for duplication CNVs
p <- results$filterParameters
plotScoringModel(expected.ht.mean = p$expected.ht.mean, expected.dup.ht.mean1 = p$expected.dup.ht.mean1,
                  expected.dup.ht.mean2 = p$expected.dup.ht.mean2, sigmoid.c1 = p$sigmoid.c1, sigmoid.c2.vector = p$sigmoid.c2.vector)


jpuntomarcos/CNVfilteR documentation built on Oct. 6, 2023, 12:37 a.m.