Biocpkg("BloodCancerMultiOmics2017")
is a multi-omic dataset comprising genome, transcriptome, DNA methylome data together with data from the ex vivo drug sensitivity screen of the primary blood tumor samples.
In this vignette we present the analysis of the Primary Blood Cancer Encyclopedia (PACE) project and source code for the paper
Drug-perturbation-based stratification of blood cancer
Sascha Dietrich*, Małgorzata Oleś*, Junyan Lu*,
Leopold Sellner, Simon Anders, Britta Velten, Bian Wu, Jennifer Hüllein, Michelle da Silva Liberio, Tatjana Walther, Lena Wagner, Sophie Rabe, Sonja Ghidelli-Disse, Marcus Bantscheff, Andrzej K. Oleś, Mikołaj Słabicki, Andreas Mock, Christopher C. Oakes, Shihui Wang, Sina Oppermann, Marina Lukas, Vladislav Kim, Martin Sill, Axel Benner, Anna Jauch, Lesley Ann Sutton, Emma Young, Richard Rosenquist, Xiyang Liu, Alexander Jethwa, Kwang Seok Lee, Joe Lewis, Kerstin Putzker, Christoph Lutz, Davide Rossi, Andriy Mokhir, Thomas Oellerich, Katja Zirlik, Marco Herling, Florence Nguyen-Khac, Christoph Plass, Emma Andersson, Satu Mustjoki, Christof von Kalle, Anthony D. Ho, Manfred Hensel, Jan Dürig, Ingo Ringshausen, Marc Zapatka,
Wolfgang Huber and Thorsten Zenz
J. Clin. Invest. (2018); 128(1):427–445. doi:10.1172/JCI93801.
The presented analysis was done by Małgorzata Oleś, Sascha Dietrich, Junyan Lu, Britta Velten, Andreas Mock, Vladislav Kim and Wolfgang Huber.
This vignette was put together by Małgorzata Oleś.
This vignette is build from the sub-vignettes, which each can be build separately. The parts are separated by the horizontal lines. Each part finishes with removal of all the created objects.
library("AnnotationDbi")
library("abind")
library("beeswarm")
library("Biobase")
library("biomaRt")
library("broom")
library("colorspace")
library("cowplot")
library("dendsort")
library("DESeq2")
library("doParallel")
library("dplyr")
library("foreach")
library("forestplot")
library("genefilter")
library("ggbeeswarm")
library("ggdendro")
library("ggplot2")
#library("ggtern")
library("glmnet")
library("grid")
library("gridExtra")
library("gtable")
library("hexbin")
# library("IHW")
library("ipflasso")
library("knitr")
library("limma")
library("magrittr")
library("maxstat")
library("nat")
library("org.Hs.eg.db")
library("BloodCancerMultiOmics2017")
library("pheatmap")
library("piano")
library("readxl")
library("RColorBrewer")
library("reshape2")
library("Rtsne")
library("scales")
library("SummarizedExperiment")
library("survival")
library("tibble")
library("tidyr")
library("xtable")
options(stringsAsFactors=FALSE)
Loading the data.
data("drpar", "drugs", "patmeta", "mutCOM")
Creating vectors of patient samples and drugs within the drug screen. Within drugs, we omit the statistics for one drug combination, due to lack of possibility to assign its targets.
# PATIENTS
patM = colnames(drpar)
# DRUGS
drM = rownames(drpar)
drM = drM[!drM %in% "D_CHK"] # remove combintation of 2 drugs: D_CHK
General plotting parameters.
bwScale = c("0"="white","1"="black","N.A."="grey90")
lfsize = 16 # legend font size
Categorize the drugs.
drugs$target_category = as.character(drugs$target_category)
drugs$group = NA
drugs$group[which(drugs$approved_042016==1)] = "FDA approved"
drugs$group[which(drugs$devel_042016==1)] = "clinical development/\ntool compound"
Show the characteristics.
tool compound | ||
---|---|---|
DNA damage response | 4 | 12 |
EGFR | 3 | 0 |
Other | 3 | 4 |
ALK | 1 | 1 |
Angiogenesis | 1 | 0 |
Apoptosis (BH3, Survivin) | 1 | 2 |
B-cell receptor | 1 | 5 |
BCR/ABL | 1 | 0 |
Epigenome | 1 | 2 |
Hedgehog signaling | 1 | 0 |
Immune modulation | 1 | 0 |
JAK/STAT | 1 | 2 |
MAPK | 1 | 7 |
PI3K/AKT | 1 | 5 |
Proteasome | 1 | 1 |
mTOR | 1 | 1 |
Cell cycle control | 0 | 6 |
Cytoskeleton | 0 | 2 |
HSP90 | 0 | 1 |
MET | 0 | 1 |
Mitochondrial metabolism | 0 | 2 |
NFkB | 0 | 2 |
NOTCH | 0 | 1 |
PIM | 0 | 1 |
PKC | 0 | 3 |
Reactive oxygen species | 0 | 3 |
Splicing | 0 | 1 |
TGF | 0 | 1 |
WNT | 0 | 1 |
Show number of samples stratified by the diagnosis.
Var1 | Freq |
---|---|
CLL | 184 |
T-PLL | 25 |
MCL | 10 |
MZL | 6 |
AML | 5 |
LPL | 4 |
B-PLL | 3 |
HCL | 3 |
hMNC | 3 |
HCL-V | 2 |
Sezary | 2 |
FL | 1 |
PTCL-NOS | 1 |
Within CLL group, we now show mutations with occurred in at least 4 samples.
# select CLL samples
patM = patM[patmeta[patM,"Diagnosis"]=="CLL"]
ighv = factor(setNames(patmeta[patM,"IGHV"], nm=patM), levels=c("U","M"))
mut1 = c("del17p13", "del11q22.3", "trisomy12", "del13q14_any")
mut2 = c("TP53", "ATM", "SF3B1", "NOTCH1", "MYD88")
mc = assayData(mutCOM)$binary[patM,]
## SELECTION OF MUTATIONS
# # include mutations with at least incidence of 4
mut2plot = names(which(sort(colSums(mc, na.rm=TRUE), decreasing=TRUE)>3))
# remove chromothrypsis
mut2plot = mut2plot[-grep("Chromothripsis", mut2plot)]
# divide mutations into gene mut and cnv
mut2plotSV = mut2plot[grep("[[:lower:]]", mut2plot)]
mut2plotSP = mut2plot[grep("[[:upper:]]", mut2plot)]
# remove some other things (it is quite manual thing, so be careful)
# IF YOU WANT TO REMOVE SOME MORE MUTATIONS JUST ADD THE LINES HERE!
mut2plotSV = mut2plotSV[-grep("del13q14_mono", mut2plotSV)]
mut2plotSV = mut2plotSV[-grep("del13q14_bi", mut2plotSV)]
mut2plotSV = mut2plotSV[-grep("del14q24.3", mut2plotSV)]
# rearrange the top ones to match the order in mut1 and mut2
mut2plotSV = c(mut1, mut2plotSV[!mut2plotSV %in% mut1])
mut2plotSP = c(mut2, mut2plotSP[!mut2plotSP %in% mut2])
factors = data.frame(assayData(mutCOM)$binary[patM, c(mut2plotSV, mut2plotSP)],
check.names=FALSE)
# change del13q14_any to del13q14
colnames(factors)[which(colnames(factors)=="del13q14_any")] = "del13q14"
mut2plotSV = gsub("del13q14_any", "del13q14", mut2plotSV)
# change it to factors
for(i in 1:ncol(factors)) {
factors[,i] = factor(factors[,i], levels=c(1,0))
}
ord = order(factors[,1], factors[,2], factors[,3], factors[,4], factors[,5],
factors[,6], factors[,7], factors[,8], factors[,9], factors[,10],
factors[,11], factors[,12], factors[,13], factors[,14],
factors[,15], factors[,16], factors[,17], factors[,18],
factors[,19], factors[,20], factors[,21], factors[,22],
factors[,23], factors[,24], factors[,25], factors[,26],
factors[,27], factors[,28], factors[,29], factors[,30],
factors[,31], factors[,32])
factorsord = factors[ord,]
patM = patM[ord]
(c(mut2plotSV, mut2plotSP))
## [1] "del17p13" "del11q22.3" "trisomy12" "del13q14" "del8p12"
## [6] "gain2p25.3" "gain8q24" "del6q21" "gain3q26" "del9p21.3"
## [11] "del15q15.1" "del6p21.2" "TP53" "ATM" "SF3B1"
## [16] "NOTCH1" "MYD88" "BRAF" "KRAS" "EGR2"
## [21] "MED12" "PCLO" "MGA" "ACTN2" "BIRC3"
## [26] "CPS1" "FLRT2" "KLHL6" "NFKBIE" "RYR2"
## [31] "XPO1" "ZC3H18"
Let’s now look deeper and for each mutation. We ask how many samples have (1) or don’t have (0) a particular mutation.
plotDF = meltWholeDF(factorsord)
plotDF$Mut =
ifelse(sapply(plotDF$X,
function(x) grep(x, list(mut2plotSV, mut2plotSP)))==1,"SV","SP")
plotDF$Status = "N.A."
plotDF$Status[plotDF$Measure==1 & plotDF$Mut=="SV"] = "1a"
plotDF$Status[plotDF$Measure==1 & plotDF$Mut=="SP"] = "1b"
plotDF$Status[plotDF$Measure==0] = "0"
plotDF$Status = factor(plotDF$Status, levels=c("1a","1b","0","N.A."))
plotDF$Y = factor(plotDF$Y, levels=patM)
plotDF$X = factor(plotDF$X, levels=rev(colnames(factorsord)))
mutPL = ggplotGrob(
ggplot(data=plotDF, aes(x=Y, y=X, fill=Status)) + geom_tile() +
scale_fill_manual(
values=c("0"="white","1a"="forestgreen","1b"="navy","N.A."="grey90"),
name="Mutation", labels=c("CNV","Gene mutation","WT","NA")) +
ylab("") + xlab("") +
geom_vline(xintercept=seq(0.5,length(patM)+1,5), colour="grey60") +
geom_hline(yintercept=seq(0.5,ncol(factorsord)+1,1), colour="grey60") +
scale_y_discrete(expand=c(0,0)) + scale_x_discrete(expand=c(0,0)) +
theme(axis.ticks=element_blank(), axis.text.x=element_blank(),
axis.text.y=element_text(
size=60, face=ifelse(levels(plotDF$X) %in% mut2plotSV,
"plain","italic")),
axis.text=element_text(margin=unit(0.5,"cm"), colour="black"),
legend.key = element_rect(colour = "black"),
legend.text=element_text(size=lfsize),
legend.title=element_text(size=lfsize)))
## Warning: Vectorized input to `element_text()` is not officially supported.
## ℹ Results may be unexpected or may change in future versions of ggplot2.
res = table(plotDF[,c("X","Measure")])
knitr::kable(res[order(res[,2], decreasing=TRUE),])
0 | 1 | |
---|---|---|
del13q14 | 69 | 106 |
TP53 | 142 | 36 |
del11q22.3 | 146 | 28 |
trisomy12 | 146 | 27 |
del17p13 | 150 | 27 |
SF3B1 | 152 | 26 |
NOTCH1 | 160 | 19 |
ATM | 89 | 11 |
BRAF | 169 | 10 |
KRAS | 136 | 8 |
del8p12 | 131 | 8 |
gain8q24 | 162 | 7 |
gain2p25.3 | 132 | 7 |
PCLO | 94 | 6 |
MED12 | 94 | 6 |
EGR2 | 94 | 6 |
del6q21 | 163 | 6 |
MGA | 95 | 5 |
MYD88 | 173 | 5 |
del15q15.1 | 134 | 5 |
del9p21.3 | 134 | 5 |
gain3q26 | 134 | 5 |
ZC3H18 | 96 | 4 |
XPO1 | 96 | 4 |
RYR2 | 96 | 4 |
NFKBIE | 96 | 4 |
KLHL6 | 96 | 4 |
FLRT2 | 96 | 4 |
CPS1 | 96 | 4 |
BIRC3 | 96 | 4 |
ACTN2 | 96 | 4 |
del6p21.2 | 135 | 4 |
In the last part, we characterize samples according to metadata categories.
Age
ageDF = data.frame(Factor="Age",
PatientID=factor(patM, levels=patM),
Value=patmeta[patM,c("Age4Main")])
agePL = ggplotGrob(
ggplot(ageDF, aes(x=PatientID, y=Factor, fill=Value)) + geom_tile() +
scale_fill_gradient(low = "gold", high = "#3D1F00", na.value="grey92",
name="Age", breaks=c(40,60,80)) +
theme(axis.ticks=element_blank(),
axis.text=element_text(size=60, colour="black",
margin=unit(0.5,"cm")),
legend.text=element_text(size=lfsize),
legend.title=element_text(size=lfsize)))
hist(ageDF$Value, col="slategrey", xlab="Age", main="")
Sex
sexDF = data.frame(Factor="Sex", PatientID=factor(patM, levels=patM),
Value=patmeta[patM, "Gender"])
sexPL = ggplotGrob(
ggplot(sexDF, aes(x=PatientID, y=Factor, fill=Value)) + geom_tile() +
scale_fill_manual(values=c("f"="maroon","m"="royalblue4","N.A."="grey90"),
name="Sex", labels=c("Female","Male","NA")) +
theme(axis.ticks=element_blank(),
axis.text=element_text(size=60, colour="black",
margin=unit(0.5,"cm")),
legend.key = element_rect(colour = "black"),
legend.text=element_text(size=lfsize),
legend.title=element_text(size=lfsize)))
table(sexDF$Value)
##
## f m
## 76 108
Treatment
Number of samples treated (1) or not treated (0) before sampling.
treatDF = data.frame(Factor="Treated", PatientID=factor(patM, levels=patM),
Value=ifelse(patmeta[patM, "IC50beforeTreatment"], 0, 1))
treatDF$Value[is.na(treatDF$Value)] = "N.A."
treatDF$Value = factor(treatDF$Value, levels=c("0","1","N.A."))
treatPL = ggplotGrob(
ggplot(treatDF, aes(x=PatientID, y=Factor, fill=Value)) +geom_tile() +
scale_fill_manual(values=bwScale, name="Treated",
labels=c("0"="No","1"="Yes","N.A."="NA")) +
theme(axis.ticks=element_blank(),
axis.text=element_text(size=60, colour="black",
margin=unit(0.5,"cm")),
legend.key = element_rect(colour = "black"),
legend.text=element_text(size=lfsize),
legend.title=element_text(size=lfsize)))
table(treatDF$Value)
##
## 0 1 N.A.
## 131 52 1
IGHV status
Number of samples with (1) and without (0) the IGHV mutation.
ighvDF = data.frame(Factor="IGHV", PatientID=factor(patM, levels=patM),
Value=patmeta[patM, "IGHV"])
ighvDF$Value = ifelse(ighvDF$Value=="M", 1, 0)
ighvDF$Value[is.na(ighvDF$Value)] = "N.A."
ighvDF$Value = factor(ighvDF$Value, levels=c("0","1","N.A."))
ighvPL = ggplotGrob(
ggplot(ighvDF, aes(x=PatientID, y=Factor, fill=Value)) + geom_tile() +
scale_fill_manual(values=bwScale, name="IGHV",
labels=c("0"="Unmutated","1"="Mutated","N.A."="NA")) +
theme(axis.ticks=element_blank(),
axis.text=element_text(size=60, colour="black", margin=unit(0.5,"cm")),
legend.key=element_rect(colour = "black"),
legend.text=element_text(size=lfsize),
legend.title=element_text(size=lfsize)))
table(ighvDF$Value)
##
## 0 1 N.A.
## 74 98 12
We performed multiple checks on the data quality. Below we show two examples.
First, we compared the values of ATP luminescence of DMSO controls at the beginning and after 48 h of incubation. Second, we assessed reproducibility of the drug screening platform.
The ATP luminescence of the samples were measured on day 0. We compared this value with the ATP luminescence of negative control wells at 48 h, in order to assess the cell viability change without drug treatment during 48 h culturing.
Loading the data.
data("lpdAll")
Prepare table for plot.
plotTab = pData(lpdAll) %>%
transmute(x=log10(ATPday0), y=log10(ATP48h), diff=ATP48h/ATPday0) %>%
filter(!is.na(x))
Scatter plot to show the the correlation of ATP luminescence between day0 and 48h.
lm_eqn <- function(df){
m <- lm(y ~ 1, df, offset = x)
ypred <- predict(m, newdata = df)
r2 = sum((ypred - df$y)^2)/sum((df$y - mean(df$y)) ^ 2)
eq <- substitute(italic(y) == italic(x) + a*","~~italic(r)^2~"="~r2,
list(a = format(coef(m)[1], digits = 2),
r2 = format(r2, digits = 2)))
as.character(as.expression(eq))
}
plotTab$ypred <- predict(lm(y~1,plotTab, offset = x), newdata = plotTab)
sca <- ggplot(plotTab, aes(x= x, y = y)) + geom_point(size=3) +
geom_smooth(data = plotTab, mapping = aes(x=x, y = ypred), method = lm, se = FALSE, formula = y ~ x) +
geom_text(x = 5.2, y = 6.2, label = lm_eqn(plotTab), parse = TRUE, size =8) +
xlab("log10(day0 ATP luminescence)") + ylab("log10(48h ATP luminescence)") +
theme_bw() + theme(axis.title = element_text(size = 15, face = "bold"),
axis.text = element_text(size=15), legend.position = "none") +
coord_cartesian(xlim = c(4.6,6.3), ylim = c(4.6,6.3))
Histogram of the difference between day0 and 48h ATP level.
histo <- ggplot(plotTab, aes(x = diff)) + geom_histogram(col = "red", fill = "red", bins=30, alpha = 0.5) + theme_bw() +
theme(axis.title = element_text(size = 15, face = "bold"), axis.text = element_text(size=15), legend.position = "none") +
xlab("(48h ATP luminescence) / (day0 ATP luminescence)")
Combine plots together.
grid.arrange(sca, histo, ncol=2)
Drug screening platform tested three samples twice. Moreover, the measurements were taken in the two time points: 48 h and 72 h after drug treatment. Here we compare the reproducibility of the screening platform by calculating Pearson correlation coefficients for the each pair of replicates.
Loading the data.
data("day23rep")
Arranging the data.
maxXY = 125
plottingDF = do.call(rbind, lapply(c("day2","day3"), function(day) {
tmp = merge(
meltWholeDF(assayData(day23rep)[[paste0(day,"rep1")]]),
meltWholeDF(assayData(day23rep)[[paste0(day,"rep2")]]),
by=c("X","Y"))
colnames(tmp) = c("PatientID", "DrugID", "ViabX", "ViabY")
tmp[,c("ViabX", "ViabY")] = tmp[,c("ViabX", "ViabY")] * 100
tmp$Day = ifelse(day=="day2", "48h", "72h")
tmp
}))
plottingDF$Shape =
ifelse(plottingDF$ViabX > maxXY | plottingDF$ViabY > maxXY, "B", "A")
Calculate the Pearson correlation coefficient.
annotation =
do.call(rbind,
tapply(1:nrow(plottingDF),
paste(plottingDF$PatientID,
plottingDF$Day, sep="_"),
function(idx) {
data.frame(X=110, Y=10,
Shape="A",
PatientID=plottingDF$PatientID[idx[1]],
Day=plottingDF$Day[idx[1]],
Cor=cor(plottingDF$ViabX[idx],
plottingDF$ViabY[idx],
method="pearson"))
}))
Plot the correlations together with coefficients (in a bottom-right corner).
#FIG# S31
ggplot(data=plottingDF,
aes(x=ifelse(ViabX>maxXY,maxXY,ViabX), y=ifelse(ViabY>maxXY,maxXY,ViabY),
shape=Shape)) +
facet_grid(Day ~ PatientID) + theme_bw() +
geom_hline(yintercept=100, linetype="dashed",color="darkgrey") +
geom_vline(xintercept=100, linetype="dashed",color="darkgrey") +
geom_abline(intercept=0, slope=1, colour="grey") +
geom_point(size=1.5, alpha=0.6) +
scale_x_continuous(limits=c(0,maxXY), breaks=seq(0,maxXY,25)) +
scale_y_continuous(limits=c(0,maxXY), breaks=seq(0,maxXY,25)) +
xlab("% viability - replicate 1") + ylab("% viability - replicate 2") +
coord_fixed() + expand_limits(x = 0, y = 0) +
theme(axis.title.x=element_text(size = rel(1), vjust=-1),
axis.title.y=element_text(size = rel(1), vjust=1),
strip.background=element_rect(fill="gainsboro")) +
guides(shape=FALSE, size=FALSE) +
geom_text(data=annotation,
aes(x=X, y=Y, label=format(Cor, digits=2), size=1.2),
colour="maroon", hjust=0.2)
## Warning: The `<scale>` argument of `guides()` cannot be `FALSE`. Use "none" instead as
## of ggplot2 3.3.4.
## This warning is displayed once every 8 hours.
## Call `lifecycle::last_lifecycle_warnings()` to see where this warning was
## generated.
The reproducibility of the measurements is high (mean 0.84).
options(stringsAsFactors=FALSE)
Loading the data.
data("lpdAll")
Here we show a relative cell viability (as compared to negative control) under treatment with 64 drugs at 5 concentrations steps each.
Prepare data.
#select drug screening data on patient samples
lpd <- lpdAll[fData(lpdAll)$type == "viab", pData(lpdAll)$Diagnosis != "hMNC"]
viabTab <- Biobase::exprs(lpd)
viabTab <- viabTab[,complete.cases(t(viabTab))]
viabTab <- reshape2::melt(viabTab)
viabTab$Concentration <- fData(lpd)[viabTab$Var1,"subtype"]
viabTab <- viabTab[viabTab$Concentration %in% c("1","2","3","4","5"),]
viabTab$drugName <- fData(lpd)[viabTab$Var1,"name"]
viabTab <- viabTab[order(viabTab$Concentration),]
#order drug by mean viablitity
drugOrder <- group_by(viabTab, drugName) %>%
summarise(meanViab = mean(value)) %>%
arrange(meanViab)
viabTab$drugName <- factor(viabTab$drugName, levels = drugOrder$drugName)
Scatter plot for viabilities and using colors for concentrations.
The plot shows high variability of effects between different drugs, from mostly lethal (left) to mostly neutral (right), concentration dependence of effects and high variability of effects of the same drug/concentration across patients.
We compared response patterns produced by drugs using phenotype clustering within diseases (CLL, T-PLL and MCL) using Pearson correlation analysis. The results imply that the drug assays probe tumor cells’ specific dependencies on survival pathways.
Loading the data.
data("drpar", "patmeta", "drugs")
Function that return the subset of samples for a given diagnosis (or all samples if diag=NA).
givePatientID4Diag = function(pts, diag=NA) {
pts = if(is.na(diag)) {
names(pts)
} else {
names(pts[patmeta[pts,"Diagnosis"]==diag])
}
pts
}
Function that returns the viability matrix for given screen (for a given channel) for patients with given diagnosis.
giveViabMatrix = function(diag, screen, chnnl) {
data = if(screen=="main") drpar
else print("Incorrect screen name.")
pid = colnames(data)
if(!is.na(diag))
pid = pid[patmeta[pid,"Diagnosis"]==diag]
return(assayData(data)[[chnnl]][,pid])
}
Color scales for the heat maps.
palette.cor1 = c(rev(brewer.pal(9, "Blues"))[1:8],
"white","white","white","white",brewer.pal(7, "Reds"))
palette.cor2 = c(rev(brewer.pal(9, "Blues"))[1:8],
"white","white","white","white",brewer.pal(7, "YlOrRd"))
Pearson correlation coefficients were calculated based on the mean drug response for the two lowest concentration steps in the main screen and across CLL and T-PLL samples separately. Square correlation matrices were plotted together, with CLL in lower triangle and T-PLL in upper triangle. The drugs in a heat map are ordered by hierarchical clustering applied to drug responses of CLL samples.
main.cll.tpll = BloodCancerMultiOmics2017:::makeCorrHeatmap(
mt=giveViabMatrix(diag="CLL", screen="main", chnnl="viaraw.4_5"),
mt2=giveViabMatrix(diag="T-PLL", screen="main", chnnl="viaraw.4_5"),
colsc=palette.cor2, concNo="one")
## Warning: Vectorized input to `element_text()` is not officially supported.
## ℹ Results may be unexpected or may change in future versions of ggplot2.
The major clusters in CLL include: kinase inhibitors targeting the B cell receptor, including idelalisib (PI3K), ibrutinib (BTK), duvelisib (PI3K), PRT062607 (SYK); inhibitors of redox signalling / reactive oxygen species (MIS−43, SD07, SD51); and BH3-mimetics (navitoclax, venetoclax).
Here we compare the effect of drugs designed to target components of the same signalling pathway.
# select the data
mtcll = as.data.frame(t(giveViabMatrix(diag="CLL",
screen="main",
chnnl="viaraw.4_5")))
colnames(mtcll) = drugs[colnames(mtcll),"name"]
# function which plots the scatter plot
scatdr = function(drug1, drug2, coldot, mtNEW, min){
dataNEW = mtNEW[,c(drug1, drug2)]
colnames(dataNEW) = c("A", "B")
p = ggplot(data=dataNEW, aes(A, B)) + geom_point(size=3, col=coldot, alpha=0.8) +
labs(x = drug1, y = drug2) + ylim(c(min, 1.35)) + xlim(c(min, 1.35)) +
theme(panel.background = element_blank(),
axis.text = element_text(size = 15),
axis.title = element_text(size = rel(1.5)),
axis.line.x = element_line(colour = "black", size = 0.5),
axis.line.y = element_line(colour = "black", size = 0.5),
panel.grid.major = element_blank(),
panel.grid.minor = element_blank()) +
geom_smooth(method=lm) +
geom_text(x=1, y=min+0.1,
label=paste0("Pearson-R = ",
round(cor(dataNEW$A, dataNEW$B ), 2)),
size = 5)
return(p)
}
## `geom_smooth()` using formula = 'y ~ x'
## `geom_smooth()` using formula = 'y ~ x'
## `geom_smooth()` using formula = 'y ~ x'
## `geom_smooth()` using formula = 'y ~ x'
## `geom_smooth()` using formula = 'y ~ x'
Pearson correlation coefficients were calculated based on the mean drug response for the two lowest concentration steps in the main screen across T-PLL samples.
main.tpll = BloodCancerMultiOmics2017:::makeCorrHeatmap(
mt=giveViabMatrix(diag="T-PLL", screen="main", chnnl="viaraw.4_5"),
colsc=palette.cor1, concNo="one")
## Warning: Vectorized input to `element_text()` is not officially supported.
## ℹ Results may be unexpected or may change in future versions of ggplot2.