-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathplot_omnibem.py
36 lines (28 loc) · 1.04 KB
/
plot_omnibem.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
"""
Use Omnibem to filter annotation data
=========================================
This example shows how to create a new genomic feature data set
from an annotation file.
"""
#####################################################
#
from gdsctools import *
data = gdsctools_data("test_omnibem_genomic_alterations.csv.gz")
bem = OmniBEMBuilder(data)
bem.filter_by_gene_list(gdsctools_data("test_omnibem_genes.txt"))
bem.plot_number_alteration_by_tissue()
#####################################################
# Finally, create a MoBEM dataframe
mobem = bem.get_mobem()
# features
bem.filter_by_type_list(["Methylation"])
mobem = bem.get_mobem()
# Then, let us create a dataframe that is compatible with
# GenomicFeature. We just need to make sure the columns are correct
mobem[[x for x in mobem.columns if x!="SAMPLE"]]
gf = GenomicFeatures(mobem[[x for x in mobem.columns if x!="SAMPLE"]])
######################################""
# The final volcano plot
an = ANOVA(ic50_test, gf, verbose=False)
results = an.anova_all(animate=False)
results.volcano()