Description Usage Arguments Value Examples
View source: R/call_all_variants.R
Call all variants from the varscan pileup2cns output and the context-specific error models. In the rare case that no model exists for that context (not enough alternate alleles), then this function uses the varscan assigned pvalue
1 | call_all_variants(sample, samp_models)
|
sample |
|
samp_models |
|
This function returns a VRanges
with the following metadata:
FlankingSeqGroup
Model Used
Model pvalue
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | ## Not run:
# Get flagged alleles and cosmic mutations
hemeCOSMIC_10 <- load_recurrent_mutations("example_data/COSMIC_heme_freq10.txt", genome = "hg19")
flagged_alleles <- get_flagged_alleles(all_sample_names, all_sample_paths,
exclude_cosmic_mutations = TRUE, cosmic_mutations = heme_COSMIC, cosmic_mut_frequency = 3)
# Load and annotate sample
samp <- load_as_VRanges(sample_name = "pt123",
sample_path = "./patient_123_pileup2cns", genome = "hg19", metadata = TRUE)
samp <- sequence_context(samp)
library(MafDb.gnomADex.r2.1.hs37d5)
annotated_samp <- annotate_MAF(varscan_output = variants,
MAF_database = MafDb.gnomADex.r2.1.hs37d5, genome = "hg19")
# Filter model input
samp_model_input <- filter_model_input(model_input = annotated_samp,
flagged_alleles = flagged_alleles, recurrent_mutations = hemeCOSMIC_10)
# Generate the error models for this sample
samp_models <- generate_all_models(sample = samp_model_input, plots = FALSE)
# Call variants for the sample based on the previously generated error models
variant_calls <- call_all_variants(annotated_samp, samp_models)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.