Skip to contents

All functions

append_annotation_links()
Function that appends multiple HTML annotation links to variant identifiers e.g. COSMIC, CLINVAR, REFSEQ etc
append_dbmts_var_link()
Function that adds miRNA target annotations (dbMTS) to genetic variant identifiers
append_dbnsfp_var_link()
Function that assigns HTML links to dbNSFP prediction entries
append_drug_var_link()
Function that adds HTML links to different genetic variant identifiers
append_gwas_citation_phenotype()
Function that adds GWAS citation/phenotype to GWAS hit found through PCGR annotation
append_otargets_pheno_link()
Function that adds HTML links to different genetic variant identifiers
append_pfeature_descriptions()
Function that adds SwissProt feature descriptions based on key identifiers coming from PCGR pipeline
append_read_support()
Function that adds read support (depth, allelic fraction) for tumor and normal and filters according to settings
append_tcga_var_link()
Function that adds TCGA annotations (cohort, frequency etc.) to variant identifiers
append_tfbs_annotation()
Function that adds TFBS annotations (dbMTS) to genetic variant identifiers
append_ucsc_segment_link()
Function that appends a link to UCSC for a genomic segment
assign_germline_popfreq_status()
Function that sets STATUS_POPFREQ_1KG_ABOVE_TOLERATED/ STATUS_POPFREQ_GNOMAD_ABOVE_TOLERATED to TRUE for variants if any population frequency exceeds max_tolerated_af
assign_mutation_type()
Function that assigns one of six mutation types to a list of mutations
assign_somatic_classification()
Function that assigns a SOMATIC_CLASSIFICATION to variants based on evidence found in variant set, potentially limited by user-defined options
assign_somatic_germline_evidence()
Function that appends several tags denoting evidence for somatic/germline status of variants
assign_tier1_tier2_acmg()
Function that assigns evidence items for SNVs/InDels to ACMG tiers 1 and 2
assign_tier1_tier2_acmg_cna()
Function that assigns evidence items for SCNAs to ACMG tiers 1 and 2
cancer_phenotypes_regex
Regular expression of terms indicative of cancer-related phenotypes and syndromes
check_common_colnames()
Function that checks whether a set of column names are present in two different data frames
clinvar_germline_status()
Function that assigns a logical to STATUS_CLINVAR_GERMLINE based on whether a ClinVar entry of germline origin is found for a given variant (for entries in a data frame)
color_palette
Color encodings for report elements of PCGR/CPSR
cosmic_somatic_status()
Function that assigns a logical (STATUS_COSMIC) reflecting whether a variant co-incides with an entry in COSMIC (germline)
cpsr_acmg
Scores and documentation of ACMG evidence criteria used for variant classification in CPSR
custom_bed_genes()
Function that reports protein-coding geneset that overlaps BED file
data_integrity_check()
Function that performs a sanity check of query VCF for pcgrr package, ensuring that all required tags are present in annotated VCF
dbsnp_germline_status()
Function that assigns a logical (STATUS_DBSNP_GERMLINE) reflecting whether a variant co-incides with an entry in dbSNP (germline)
deduplicate_eitems()
Function that removes redundancy in variant evidence items (i.e. if a variant is assicated with evidence at the codon level, evidence at the exon/gene level is ignored)
detect_vcf_sample_name()
A function that detects whether the sample name in variant data frame is unique (as present in column name VCF_SAMPLE_ID), throws an error if multiple sample names are present for the CPSR workflow
determine_genotype()
Function that assigns explicit genotype (heterozygous/homozygous) from VCF GT tag
df_string_replace()
Function that performs stringr::str_replace on strings of multiple string columns of a dataframe
effect_prediction_algos
List of URLs for a range of variant effect prediction algorithms
filter_eitems_by_site()
Function that filters clinical evidence items by tumor type/primary site
filter_read_support()
Function that filters variant set on (depth, allelic fraction) for tumor and normal and filters according to settings
generate_annotation_link()
A function that generates a HTML link for selected identifiers (DBSNP, COSMIC, CLINVAR, ENTREZ)
generate_pcgr_report()
Function that generates all contents of the cancer genome report (PCGR)
generate_report_data_cna()
Function that annotates CNV segment files
generate_report_data_kataegis()
Function that generates data frame with potential kataegis events
generate_report_data_msi()
Function that generates MSI prediction data for PCGR report
generate_report_data_rainfall()
Function that generates data for rainfall plot (mutation density along genome, considering SNVs only)
generate_report_data_signatures_mp()
Function that generates mutational signatures data for PCGR report
generate_report_data_snv_indel()
Function that generates tiered variant sets for SNVs/InDels
generate_report_data_tmb()
Function that tiered variant sets for SNVs/InDels
generate_report_data_trials()
Function that retrieves relevant (interventional based on molecular target) clinical trials for a given tumor type
generate_report_data_tumor_only()
Function that generates germline-filtered callset and PCGR report statistics for a given tumor-only callsets
generate_report_data_value_box()
Function that generates value box data for PCGR report
generate_tier_tsv()
Function that generates dense and tiered annotated variant datasets
get_calls()
Function that reads a fully annotated VCF from PCGR VEP/vcfanno pipeline
get_clin_assocs_cna()
Function that retrieves clinical evidence items (CIVIC, CBMDB) for CNA aberrations
get_clin_assocs_snv_indel()
Function that matches clinical evidence items (CIVIC, CBMDB) against somatic cancer variants detected in tumor
get_cna_cytoband()
Function that gets the chromosome bands of copy number segments
get_cna_overlapping_transcripts()
Functions that finds all transcripts that overlap with CNA segments. A new data frame with one entry per transcript-CNA overlap entry is returned
get_genome_obj()
Get BSgenome Object
get_oncogene_tsgene_target_sets()
Function that detects and assigns oncogenes subject to copy number amplifications, and tumor suppressor genes subject to homozygous deletions Also detects other drug targets subject to copy number amplifications
get_ordinary_chromosomes()
Function that excludes genomic aberrations from non-nuclear chromosomes
get_population_tag()
Function that retrieves name of VCF INFO tag and population description for gnomad/1000G population
get_prevalent_site_signatures()
Function that retrieves prevalent signatures for a given tumor type/primary site Data is collected from COSMIC v3.2.
get_proper_maf_alleles()
Function that transforms a tier-structured variant data frame into a MAF-like data frame (for input to 2020plus, MutSigCV)
get_valid_chromosome_segments()
Function that removes copy number segments that go beyond chrosomal lengths for the given assembly
get_valid_chromosomes()
Checks for valid chromosome names in data frame of variants
het_af_germline_status()
Function that assigns a logical (STATUS_LIKELY_GERMLINE_HETEROZYGOUS) reflecting whether a variant is likely heterozygous (germline) - based on allelic fraction (AF_TUMOR), presence in gnomAD and dbSNP, and no presence in TCGA and COSMIC
heterozygous_states
VCF encodings of heterozygous variant states
hom_af_status()
Function that assigns a logical (STATUS_LIKELY_GERMLINE_HOMOZYGOUS) reflecting whether a variant is likely homozygous (germline) - based on allelic fraction (AF_TUMOR)
homozygous_states
VCF encodings of homozygous variant states
init_cna_content()
Function that initiates report element with CNA information
init_germline_content()
Function that initiates report element with germline variant information (CPSR)
init_m_signature_content()
Function that initiates report element with mutational signatures information
init_rainfall_content()
Function that initiates report element with rainfall information
init_report()
Function that initiates PCGR/CPSR report object
init_report_display_content()
Function that initiates ranked report display information
init_snv_indel_content()
Function that initiates report element with SNV/InDel information
init_tmb_content()
Function that initiates report element with TMB information
init_tumor_only_content()
Function that initiates report element with tumor-only information
init_valuebox_content()
Function that initiates report element with value box information
init_var_content()
Function that initiates report element with variant data
kataegis_detect()
Function that detects kataegis events from a data frame with genomic cooordinates of mutations
kataegis_input()
Function that detects kataegis events from a data frame with genomic cooordinates of mutations
load_all_eitems()
Function that loads all evidence items from CIViC and CGI, and combines them in a unified data.frame
load_eitems()
Function that loads specific set of clinical variant evidence items (CIViC + CGI) based on given parameters (mutation type, variant origin, tumor type etc)
log4r_debug()
Write messages to logs at a given priority level
log4r_info()
Write messages to logs at a given priority level
log4r_warn()
Write messages to logs at a given priority level
log_var_eitem_stats()
Function that logs the number of evidence items found, for different levels of resolution
make_upset_plot_data()
Function that makes input data for an UpSet plot (filtering/intersection results) for the somatic-germline classification procedure
match_eitems_to_var()
Function that matches variants to evidence items
max_af_gnomad()
Function that assigns a maximum value to a variable (MAX_AF_GNOMAD) reflecting the maximum allele frequency for a given variant across gnomAD populations
max_af_onekg()
Function that assigns a maximum value to a variable (MAX_AF_1KG) reflecting the maximum allele frequency for a given variant across oneKG populations
msi_indel_fraction_plot()
Function that plots the indel fraction for a given sample and contrasts this with the distribution for MSI-H/MSS samples from TCGA
order_variants()
Function that orders genomic aberrations according to order of chromosomes and chromosomal position
pkg_exists()
Does R Package Exist
plot_tmb_primary_site_tcga()
Function that makes a plot with TMB boxplots for TCGA cohorts, highlighting the TMB estimate for a given sample and the cohort/primary site of interest
plot_value_boxes()
Function that plots four value boxes with the most important findings in the cancer genome
pon_status()
Function that assigns a logical (STATUS_PON) reflecting whether a variant is co-inciding with a variant present in a panel-of-normals database (PANEL_OF_NORMALS column is TRUE)
predict_msi_status()
Function that predicts MSI status based on fraction of indels among calls
qc_var_eitems()
Function that makes a quality control check of evidence items assigned to variants
recode_logical_vars()
Function that assigns proper logical values to logical entries read from VCF file (TRUE = True (VCF), FALSE = False (VCF))
remove_cols_from_df()
Function that removes column(s) from data frame
set_report_metadata()
Function that set PCGR report metadata
sort_chromosomal_segments()
Function that sorts chromosomal segments according to chromosome and chromosomal start/end position
structure_var_eitems()
Function that structures variant evidence items according to strength of evidence
targeted_drugs_pr_ttype()
Function that retrieves targeted drugs for a given tumor type/primary site
targeted_drugs_summarise()
Function that summarises available targeted drugs for a given target
tcga_somatic_status()
Function that assigns a logical (STATUS_TCGA_SOMATIC) reflecting whether a variant co-incides with an entry in TCGA (somatic)
tier_af_distribution()
Function that plots a histogram of the the variant allelic support (tumor) - grouped by tiers
update_maf_allelic_support()
Function that updates a MAF file (produced by vcf2maf) with allelic support data
update_report()
Function that initates PCGR report object
upset_plot_tumor_only()
Function that makes an upset calls for germline-filtered variants classification procedure
variant_db_url
List of URLS and variant identifiers for variant/gene/protein domain databases
variant_stats_report()
Function that generate snv/indel + coding/noncoding stats for a given variant set
virtual_panel_display_html()
Function that makes a HTML display of virtual gene panel
write_processed_vcf()
Function that writes a VCF intended for mutational signature analysis
write_report_output()
Function that writes contents of PCGR object to various output formats (Rmarkdown/flexdashboard HTML reports, JSON, tab-separated etc)