heatmap_clones_gene_pat: Heatmaps of gene pairs of interest

Description Usage Arguments Details Value Author(s) Examples

View source: R/plot_functions.R

Description

This function plots the heatmaps of final gene clone matrices.

Usage

1
2
heatmap_clones_gene_pat(pairs_of_interest, clone_tbl, all_genes_tbl,
  first_clone_is_N = FALSE, output_pdf = "direct")

Arguments

pairs_of_interest

The tibble containing the pairs of genes/pathways that should be visualized in the heatmap. This may be, e.g. the gene pairs were mle_delta > 0, qval < 0.1, and num_patients > 1. It contains the columns 'entity_A', and 'entity_B', and can be generated with GeneAccord. For the plot, the function will attempt to map the gene ID's from ensembl ID to gene name. However, if the input genes are not ensembl IDs, it does not matter.

clone_tbl

The tibble containing the information of which gene/pathway is mutated in which clone from which patient. Here, it is assumed that only one tree from the collection of trees was chosen per patient.

all_genes_tbl

A tibble with all genes ensembl id's and hgnc symbols. Can be created with create_ensembl_gene_tbl_hg.

first_clone_is_N

Logical indicating whether the first clone column is actually representing the normal or germline, and is not a tumor clone. In that case, it will have the name 'N', and all other columns will be one clone number smaller, e.g. 'clone2' is then actually 'clone1' etc. Default: FALSE.

output_pdf

The name of the pdf to be generated. Or if output_pdf is "direct", then the plot is generated directly and not to a pdf. Default: "direct"

Details

After running the GeneAccord, one may want to visualize the gene clone heatmap for significant gene pairs.

Value

None, the function plots a gene-to-clone assignment heatmap.

Author(s)

Ariane L. Moore

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
pairs_of_interest <- dplyr::tibble(entity_A="SETD2",
                           entity_B="BAP1")
clone_tbl <- dplyr::tibble(
               file_name=c("X.csv", "X.csv", "Y.csv", "Y.csv"),
               patient_id=c("X", "X", "Y", "Y"),
               altered_entity=c("SETD2", "BAP1", "SETD2", "BAP1"),
               clone1=c(0, 1, 1, 0),
               clone2=c(1, 0, 0, 1))
## Not run: all_genes_tbl <- create_ensembl_gene_tbl_hg()
all_genes_tbl_example <- dplyr::tibble(
                 ensembl_gene_id=c("ENSG00000181555", 
                 "ENSG00000163930"),
                 hgnc_symbol=c("SETD2", "BAP1"))
heatmap_clones_gene_pat(pairs_of_interest, clone_tbl, 
all_genes_tbl_example)

Example output



GeneAccord documentation built on Nov. 8, 2020, 8:04 p.m.