plot_literature_score: plot_literature_score

Description Usage Arguments Value Examples

View source: R/plot_literature_score.R

Description

Plots a non-clusterized heatmap of the article counts for the combination of gene list and list of terms NOTE: the object has to be exactly the one returned by get_literature_score.R . Otherwise ggplot2 will not be able to identify the correct columns.

Usage

1
2
plot_literature_score(plot_counts, return_ggplot = FALSE,
  is_plotly = FALSE)

Arguments

plot_counts

The dataframe returned from the get_literature_score function

return_ggplot

If TRUE, returns a ggplot2 object instead of plotting. Defaults to FALSE.

is_plotly

If TRUE, a interactive plot is plotted in the place o static ggplot. Defaults to FALSE.

Value

A ggplot2 object is either returned or directly plotted

Examples

1
2
3
4
5
6
7
  gene <- c('CD4','CD14', "AIF1", "ACVR1", "CDY2A")
  terms_of_interest <- c("CD4 T cell", "CD14+ Monocyte", "B cell",
  "CD8 T cell","FCGR3A+ Monocyte", "NK cell", "Dendritic cell",
  "Megakaryocyte", 'immunity')
  literature_counts <- get_literature_score(gene, terms_of_interest)
  P <-plot_literature_score(literature_counts, return_ggplot = TRUE)
  plot(P)

lubianat/PubScore documentation built on Dec. 14, 2019, 10:24 p.m.