In [1]:
from FOXREG import ComparisonTree
import pandas as pd
import warnings
warnings.filterwarnings("ignore")
source: https://www.nature.com/articles/s41591-019-0695-9 dataset¶
vignette_steps please see: https://smorabit.github.io/hdWGCNA/articles/basic_tutorial.html¶
In [2]:
start_path = "/Users/mosesapostol/Desktop/FoxWEBSITE/FOX-Functional-OMIC-eXploration/data/Supplemental_example_Zhou_pt2/"
df_MG_RSS = pd.read_csv("{}/20_modules_Jul11_RSS.csv".format(start_path))
df_MG_RAS = pd.read_csv("{}/RAS_values_dataset_Zhou_20.csv".format(start_path))
threshold_file = "{}/3.5_regulon_scores_thresholds.tsv".format(start_path)
In [3]:
cell_Types = [
"EX", "INH", "ASC", "OPC", "MG", "ODC"
]
Zhou = ComparisonTree("EX", df_MG_RAS, "cell_type", df_MG_RSS,
cell_Types, "Unnamed: 0", threshold_file)
Zhou.construct_tree()
regulon_sig_ZHou_pb = {}
for i in cell_Types:
p_vals = Zhou.plotRSS_NMF(i, drawQuadrants=True, include_pvals=True)
regulon_sig_ZHou_pb[i] = p_vals
Zhou.plot_3dEmbedding()
ODC -0.7789473684210527 ASC -0.2631578947368421 MG -0.052631578947368425 OPC 0.052631578947368425 INH 0.5263157894736842 EX 1.0 ODC ASC MG OPC INH
['EX', 'INH', 'ASC', 'OPC', 'MG', 'ODC'] ['black', 'blue', 'brown', 'cyan', 'green', 'greenyellow', 'grey60', 'lightcyan', 'lightgreen', 'lightyellow', 'magenta', 'midnightblue', 'pink', 'purple', 'red', 'royalblue', 'salmon', 'tan', 'turquoise', 'yellow'] {'ODC': '#ecc235', 'ASC': '#1c1125', 'MG': '#cd881b', 'OPC': '#4bd870', 'INH': '#747fab'}
In [ ]: