4.1 - Scatter plots


library(ELMER.data)
library(ELMER)
library(DT)
library(dplyr)
library(BiocStyle)

Loading required data for plot

# Load results from previous sections
mae <- get(load("mae.rda"))

Scatter plots

Scatter plot of one probe and its nearby genes

Generate scatter plots for one probes' nearby 20 gene expression vs DNA methylation at this probe.

Each scatter plot shows the methylation level of an example probe cg19403323 in all LUSC samples plotted against the expression of one of 20 adjacent genes.

scatter.plot(data = mae,
             byProbe = list(probe = c("cg19403323"), numFlankingGenes = 20), 
             category = "definition", 
             lm = TRUE, # Draw linear regression curve
             save = FALSE) 

Scatter plot of one pair

Generate a scatter plot for one probe-gene pair. Figure \ref{fig:figure2}

Scatter plot shows the methylation level of an example probe cg19403323 in all LUSC samples plotted against the expression of the putative target gene SYT14.

scatter.plot(data = mae,
             byPair = list(probe = c("cg19403323"), gene = c("ENSG00000143469")), 
             category = "definition", save = TRUE, lm_line = TRUE) 

TF expression vs. average DNA methylation

Generate scatter plot for TF expression vs average DNA methylation of the sites with certain motif.

Each scatter plot shows the average methylation level of sites with the TP53 motif in all LUSC samples plotted against the expression of the transcription factor TP53, TP63, TP73 respectively.

load("result/getMotif.hypo.enriched.motifs.rda")
names(enriched.motif)[1]
scatter.plot(data = mae,
             byTF = list(TF = c("TP53","SOX2"),
                         probe = enriched.motif[[names(enriched.motif)[1]]]), 
             category = "definition",
             save = TRUE, 
             lm_line = TRUE)


Try the ELMER package in your browser

Any scripts or data that you put into this service are public.

ELMER documentation built on Nov. 8, 2020, 4:59 p.m.