Last updated: 2022-05-31
Checks: 6 1
Knit directory: EMBL2016/analysis/
This reproducible R Markdown analysis was created with workflowr (version 1.7.0). The Checks tab describes the reproducibility checks that were applied when the results were created. The Past versions tab lists the development history.
The R Markdown is untracked by Git. To know which version of the R
Markdown file created these results, you’ll want to first commit it to
the Git repo. If you’re still working on the analysis, you can ignore
this warning. When you’re finished, you can run
wflow_publish
to commit the R Markdown file and build the
HTML.
Great job! The global environment was empty. Objects defined in the global environment can affect the analysis in your R Markdown file in unknown ways. For reproduciblity it’s best to always run the code in an empty environment.
The command set.seed(20210512)
was run prior to running
the code in the R Markdown file. Setting a seed ensures that any results
that rely on randomness, e.g. subsampling or permutations, are
reproducible.
Great job! Recording the operating system, R version, and package versions is critical for reproducibility.
Nice! There were no cached chunks for this analysis, so you can be confident that you successfully produced the results during this run.
Great job! Using relative paths to the files within your workflowr project makes it easier to run your code on other machines.
Great! You are using Git for version control. Tracking code development and connecting the code version to the results is critical for reproducibility.
The results in this page were generated with repository version 12d1722. See the Past versions tab to see a history of the changes made to the R Markdown and HTML files.
Note that you need to be careful to ensure that all relevant files for
the analysis have been committed to Git prior to generating the results
(you can use wflow_publish
or
wflow_git_commit
). workflowr only checks the R Markdown
file, but you know if there are other scripts or data files that it
depends on. Below is the status of the Git repository when the results
were generated:
Ignored files:
Ignored: .DS_Store
Ignored: .Rhistory
Ignored: analysis/.DS_Store
Ignored: analysis/.Rhistory
Ignored: analysis/CDK_analysis_cache/
Ignored: analysis/boxplot_AUC.png
Ignored: analysis/consensus_clustering_CPS_cache/
Ignored: analysis/consensus_clustering_noFit_cache/
Ignored: analysis/dose_curve.png
Ignored: analysis/targetDist.png
Ignored: analysis/toxivity_box.png
Ignored: analysis/volcano.png
Ignored: data/.DS_Store
Ignored: output/.DS_Store
Untracked files:
Untracked: analysis/AUC_CLL_IC50/
Untracked: analysis/BRAF_analysis.Rmd
Untracked: analysis/CDK_analysis.Rmd
Untracked: analysis/GSVA_analysis.Rmd
Untracked: analysis/NOTCH1_signature.Rmd
Untracked: analysis/autoluminescence.Rmd
Untracked: analysis/bar_plot_mixed.pdf
Untracked: analysis/bar_plot_mixed_noU1.pdf
Untracked: analysis/beatAML/
Untracked: analysis/cohortComposition_CLLsamples.pdf
Untracked: analysis/cohortComposition_allSamples.pdf
Untracked: analysis/consensus_clustering.Rmd
Untracked: analysis/consensus_clustering_CPS.Rmd
Untracked: analysis/consensus_clustering_IC50.Rmd
Untracked: analysis/consensus_clustering_beatAML.Rmd
Untracked: analysis/consensus_clustering_noFit.Rmd
Untracked: analysis/consensus_clusters.pdf
Untracked: analysis/disease_specific.Rmd
Untracked: analysis/dose_curve_selected.pdf
Untracked: analysis/drugScreens_reproducibility.Rmd
Untracked: analysis/genomic_association.Rmd
Untracked: analysis/genomic_association_allDisease.Rmd
Untracked: analysis/mean_autoluminescence_val.csv
Untracked: analysis/mean_autoluminescence_val.xlsx
Untracked: analysis/noFit_CLL/
Untracked: analysis/number_associations.pdf
Untracked: analysis/overview.Rmd
Untracked: analysis/plotCohort.Rmd
Untracked: analysis/preprocess.Rmd
Untracked: analysis/volcano_noBlocking.pdf
Untracked: code/utils.R
Untracked: data/BeatAML_Waves1_2/
Untracked: data/ic50Tab.RData
Untracked: data/newEMBL_20210806.RData
Untracked: data/patMeta.RData
Untracked: data/targetAnnotation_all.csv
Untracked: output/gene_associations/
Untracked: output/resConsClust.RData
Untracked: output/resConsClust_aucFit.RData
Untracked: output/resConsClust_beatAML.RData
Untracked: output/resConsClust_cps.RData
Untracked: output/resConsClust_ic50.RData
Untracked: output/resConsClust_noFit.RData
Untracked: output/screenData.RData
Unstaged changes:
Modified: _workflowr.yml
Modified: analysis/_site.yml
Deleted: analysis/about.Rmd
Modified: analysis/index.Rmd
Deleted: analysis/license.Rmd
Note that any generated files, e.g. HTML, png, CSS, etc., are not included in this status report because it is ok for generated content to have uncommitted changes.
There are no past versions. Publish this analysis with
wflow_publish()
to start tracking its development.
Load screen datasets
load("~/CLLproject_jlu/var/newEMBL_processed_20220506.RData")
load("~/CLLproject_jlu/var/IC50_170823.RData")
Select overlapped patients and drugs
screenEMBL <- emblNew
screenIC50 <- ic50
commonPat <- intersect(screenIC50$patientID, screenEMBL$patID)
drugMap <- read.csv2("~/CLLproject_jlu/data/targetAnno/targetAnnotation_all.csv")
screenEMBL <- screenEMBL %>% left_join(select(drugMap, nameEMBL2016, nameIC50), by = c(name = "nameEMBL2016")) %>%
filter(!is.na(nameIC50)) %>%
mutate(concIndex =factor(concIndex)) %>%
distinct(patID, nameIC50, concIndex, .keep_all = TRUE) %>%
dplyr::rename(patientID = patID, Drug = nameIC50, Concentration = conc)
Merge dataset
screenCom <- select(screenIC50, patientID, sampleID, Drug, normVal, normVal_auc, normVal.cor_auc, diagnosis, concIndex, Concentration) %>%
mutate(normVal.cor = normVal,normVal_auc.cor = normVal_auc) %>%
dplyr::rename(sampleID.ic50 = sampleID, normVal.ic50 = normVal,
normVal.cor.ic50 = normVal.cor, conc.ic50 = Concentration,
auc.ic50 = normVal_auc, auc.cor.ic50 = normVal_auc.cor,
concIndex.ic50 = concIndex) %>%
left_join(select(screenEMBL, patientID, sampleID, Drug, normVal,
normVal.sigm, concIndex, Concentration, normVal_auc.sigm, normVal_auc),
by = c("Drug","patientID")) %>%
dplyr::rename(sampleID.embl = sampleID, normVal.embl = normVal,
normVal.cor.embl = normVal.sigm,
auc.embl = normVal_auc, auc.cor.embl = normVal_auc.sigm,
conc.embl = Concentration, concIndex.embl = concIndex) %>%
filter(!is.na(sampleID.embl))
How many overlapped patients
length(commonPat)
[1] 94
Among those patients, how many patients have the same samples used for screening?
smpTab <- screenCom %>% distinct(patientID, .keep_all = TRUE) %>%
mutate(sameSmp = sampleID.ic50 == sampleID.embl)
table(smpTab$sameSmp)
FALSE TRUE
36 58
R^2 valules
# A tibble: 57 × 3
Drug r2 r2.cor
<fct> <dbl> <dbl>
1 thapsigargin 0.540 0.508
2 dasatinib 0.386 0.404
3 YM155 0.354 0.362
4 ibrutinib 0.353 0.387
5 PF 477736 0.318 0.325
6 KX2-391 0.296 0.346
7 spebrutinib 0.291 0.279
8 nutlin-3 0.243 0.257
9 duvelisib 0.203 0.226
10 sotrastaurin 0.187 0.234
# … with 47 more rows
Scatter plot: IC50 VS EMBL2016 (uncorrected data)
Scatter plot: CPS1000 VS EMBL2016 (edge effect corrected data)
R^2 valules
# A tibble: 57 × 3
Drug r2 r2.cor
<fct> <dbl> <dbl>
1 thapsigargin 0.605 0.572
2 PF 477736 0.597 0.570
3 dasatinib 0.462 0.470
4 ibrutinib 0.374 0.411
5 YM155 0.367 0.373
6 AZD7762 0.353 0.369
7 KX2-391 0.325 0.359
8 spebrutinib 0.304 0.243
9 actinomycin D 0.279 0.271
10 duvelisib 0.265 0.262
# … with 47 more rows
Scatter plot: IC50 VS EMBL2016 (uncorrected data)
Scatter plot: CPS1000 VS EMBL2016 (edge effect corrected data)
r2Compare <- bind_rows(mutate(r2Tab, type = "samePatient"),
mutate(r2Tab.smp, type ="sameSample")) %>%
pivot_longer(c("r2","r2.cor"), names_to = "correction", values_to = "r2") %>%
mutate(type = paste0("R2_",type)) %>%
pivot_wider(names_from = type, values_from = r2) %>%
mutate(correction = ifelse(correction == "r2","non-corrected","edge-corrected"))
ggplot(r2Compare, aes(x=R2_samePatient, y=R2_sameSample)) +
geom_point() +
geom_abline(intercept = 0, slope = 1, linetype = "dashed", color = "red") +
facet_wrap(~correction)
write_csv2(r2Compare, file = "../docs/R2_compare.csv")
When samples are the same, R2 is relatively higher.
Download csv table: R2_compare.csv
Calculate r2 for each concentration, enumerate all pairs.
Plot the r2 for all concentration pairs in a heatmap
Select the concentration pair with best reproducibility
# A tibble: 57 × 5
Drug r2 r2.cor conc.embl conc.ic50
<chr> <dbl> <dbl> <int> <int>
1 nutlin-3 0.636 0.636 2 1
2 KX2-391 0.603 0.626 2 1
3 PF 477736 0.551 0.513 2 3
4 sotrastaurin 0.545 0.553 2 2
5 thapsigargin 0.533 0.468 2 1
6 navitoclax 0.488 0.566 4 2
7 rigosertib 0.487 0.515 3 1
8 vorinostat 0.472 0.483 3 2
9 dasatinib 0.458 0.468 4 2
10 TAE684 0.450 0.454 2 2
# … with 47 more rows
Scatter plot (uncorrected)
Scatter plot (edge effect corrected)
sessionInfo()
R version 4.2.0 (2022-04-22)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Big Sur/Monterey 10.16
Matrix products: default
BLAS: /Library/Frameworks/R.framework/Versions/4.2/Resources/lib/libRblas.0.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.2/Resources/lib/libRlapack.dylib
locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] forcats_0.5.1 stringr_1.4.0 dplyr_1.0.9
[4] purrr_0.3.4 readr_2.1.2 tidyr_1.2.0
[7] tibble_3.1.7 tidyverse_1.3.1 readxl_1.4.0
[10] ggplot2_3.3.6 gridExtra_2.3 robustbase_0.95-0
[13] jyluMisc_0.1.5 colorspace_2.0-3 RColorBrewer_1.1-3
[16] Biobase_2.56.0 BiocGenerics_0.42.0
loaded via a namespace (and not attached):
[1] backports_1.4.1 fastmatch_1.1-3
[3] drc_3.0-1 workflowr_1.7.0
[5] igraph_1.3.1 shinydashboard_0.7.2
[7] splines_4.2.0 BiocParallel_1.30.2
[9] GenomeInfoDb_1.32.2 TH.data_1.1-1
[11] digest_0.6.29 htmltools_0.5.2
[13] fansi_1.0.3 magrittr_2.0.3
[15] cluster_2.1.3 tzdb_0.3.0
[17] limma_3.52.1 modelr_0.1.8
[19] matrixStats_0.62.0 vroom_1.5.7
[21] sandwich_3.0-1 piano_2.12.0
[23] rvest_1.0.2 haven_2.5.0
[25] xfun_0.31 crayon_1.5.1
[27] RCurl_1.98-1.6 jsonlite_1.8.0
[29] survival_3.3-1 zoo_1.8-10
[31] glue_1.6.2 survminer_0.4.9
[33] gtable_0.3.0 zlibbioc_1.42.0
[35] XVector_0.36.0 DelayedArray_0.22.0
[37] car_3.0-13 DEoptimR_1.0-11
[39] abind_1.4-5 scales_1.2.0
[41] mvtnorm_1.1-3 DBI_1.1.2
[43] relations_0.6-12 rstatix_0.7.0
[45] Rcpp_1.0.8.3 plotrix_3.8-2
[47] xtable_1.8-4 bit_4.0.4
[49] km.ci_0.5-6 stats4_4.2.0
[51] DT_0.23 htmlwidgets_1.5.4
[53] httr_1.4.3 fgsea_1.22.0
[55] gplots_3.1.3 ellipsis_0.3.2
[57] farver_2.1.0 pkgconfig_2.0.3
[59] sass_0.4.1 dbplyr_2.1.1
[61] utf8_1.2.2 labeling_0.4.2
[63] tidyselect_1.1.2 rlang_1.0.2
[65] later_1.3.0 munsell_0.5.0
[67] cellranger_1.1.0 tools_4.2.0
[69] visNetwork_2.1.0 cli_3.3.0
[71] generics_0.1.2 broom_0.8.0
[73] evaluate_0.15 fastmap_1.1.0
[75] yaml_2.3.5 bit64_4.0.5
[77] knitr_1.39 fs_1.5.2
[79] survMisc_0.5.6 caTools_1.18.2
[81] nlme_3.1-157 mime_0.12
[83] slam_0.1-50 xml2_1.3.3
[85] compiler_4.2.0 rstudioapi_0.13
[87] ggsignif_0.6.3 marray_1.74.0
[89] reprex_2.0.1 bslib_0.3.1
[91] stringi_1.7.6 highr_0.9
[93] lattice_0.20-45 Matrix_1.4-1
[95] shinyjs_2.1.0 KMsurv_0.1-5
[97] vctrs_0.4.1 pillar_1.7.0
[99] lifecycle_1.0.1 jquerylib_0.1.4
[101] data.table_1.14.2 cowplot_1.1.1
[103] bitops_1.0-7 httpuv_1.6.5
[105] GenomicRanges_1.48.0 R6_2.5.1
[107] promises_1.2.0.1 KernSmooth_2.23-20
[109] IRanges_2.30.0 codetools_0.2-18
[111] MASS_7.3-57 gtools_3.9.2
[113] exactRankTests_0.8-35 assertthat_0.2.1
[115] SummarizedExperiment_1.26.1 rprojroot_2.0.3
[117] withr_2.5.0 multcomp_1.4-19
[119] S4Vectors_0.34.0 GenomeInfoDbData_1.2.8
[121] mgcv_1.8-40 parallel_4.2.0
[123] hms_1.1.1 grid_4.2.0
[125] rmarkdown_2.14 MatrixGenerics_1.8.0
[127] carData_3.0-5 git2r_0.30.1
[129] maxstat_0.7-25 ggpubr_0.4.0
[131] sets_1.0-21 shiny_1.7.1
[133] lubridate_1.8.0