R/plots.R
plotTargetingDrugsVSsimilarPerturbations.Rd
Plot similar perturbations against predicted targeting drugs
plotTargetingDrugsVSsimilarPerturbations(
targetingDrugs,
similarPerturbations,
column,
labelBy = "pert_iname",
quantileThreshold = 0.25,
showAllScores = FALSE,
keyColTargetingDrugs = NULL,
keyColSimilarPerturbations = NULL
)
targetingDrugs
object
similarPerturbations
object
Character: column to plot (must be available in both databases)
Character: column in as.table(similarPerturbations)
or
as.table(targetingDrugs)
to be used for labelling
Numeric: quantile (between 0 and 1) to highlight values of interest
Boolean: show all scores? If FALSE
, only the best
score per compound will be plotted
Character: column from targetingDrugs
to
compare with column keyColSimilarPerturbations
from
similarPerturbations
; automatically selected if NULL
Character: column from
similarPerturbations
to compare with column
keyColTargetingDrugs
from targetingDrugs
; automatically
selected if NULL
ggplot2
plot
Other functions related with the ranking of CMap perturbations:
as.table.referenceComparison()
,
filterCMapMetadata()
,
getCMapConditions()
,
getCMapPerturbationTypes()
,
loadCMapData()
,
loadCMapZscores()
,
parseCMapID()
,
plot.perturbationChanges()
,
plot.referenceComparison()
,
prepareCMapPerturbations()
,
print.similarPerturbations()
,
rankSimilarPerturbations()
Other functions related with the prediction of targeting drugs:
as.table.referenceComparison()
,
listExpressionDrugSensitivityAssociation()
,
loadExpressionDrugSensitivityAssociation()
,
plot.referenceComparison()
,
predictTargetingDrugs()
# Rank similarity against CMap compound perturbations
similarPerts <- rankSimilarPerturbations(diffExprStat,
cmapPerturbationsCompounds)
#> Subsetting data based on 8790 intersecting genes (65% of the 13451 input genes)...
#> Comparing against 22 CMap perturbations (2 cell lines) using 'spearman, pearson, gsea' (gene size of 150)...
#> Comparison performed in 1.15 secs
# Predict targeting drugs
gdsc <- loadExpressionDrugSensitivityAssociation("GDSC 7")
#> Loading data from expressionDrugSensitivityCorGDSC7.qs...
predicted <- predictTargetingDrugs(diffExprStat, gdsc)
#> Subsetting data based on 11396 intersecting genes (85% of the 13451 input genes)...
#> Comparing against 266 GDSC 7 compounds (983 cell lines) using 'spearman, pearson, gsea' (gene size of 150)...
#> Comparison performed in 2.58 secs
plotTargetingDrugsVSsimilarPerturbations(predicted, similarPerts,
"spearman_rank")
#> Columns 'name' and 'pubchem_cid' were matched based on 0 common values; to manually select columns to compare, please set arguments starting with 'keyCol'
#> Warning: No shared levels found between `names(values)` of the manual scale and the
#> data's colour values.