rohitarorayyc / SpatialTranscriptomics

Spatial Transcriptomic Analysis of OSCC samples
GNU General Public License v3.0
17 stars 5 forks source link

A quick question about setting perturbation score for simulating the drug effect #3

Closed HelloWorldLTY closed 8 months ago

HelloWorldLTY commented 8 months ago

Hi, thanks for your great work again! When I read your codes to implement the in-silico drug perturbaiton discovery, I found an interesting step to perform perturbation:

def perturb_condition(adata_pt, genes_up, genes_down, genes_total, i, ic50_dgidb, ic50_dgidb_scored):
    if (len(genes_up) >= 1 and len(genes_down) >= 1):
        print("up and down")
        expr_vals = [-200] * len(genes_down) + [200] * len(genes_up)
    elif (len(genes_up) >= 1 and len(genes_down) == 0):
        print("only up")
        expr_vals = [200] * len(genes_up)
    elif (len(genes_up) == 0 and len(genes_down) >= 1):
        print("only down")
        expr_vals = [-200] * len(genes_down)
    else:
        print("no perturb")
        return ic50_dgidb_scored

    ic50_dgidb_scored = run_perturb_analysis(adata_pt, genes_total, expr_vals, i, ic50_dgidb, ic50_dgidb_scored)
    return ic50_dgidb_scored

It seems that the expression changed of genes are liminited by magnitude as 200. I know the original dynamo used 100, but I wonder if it is possible to quantify such magnitude, since I think different drugs should have different activation or inhibition strength for different group of genes. Thanks a lot.

rohitarorayyc commented 8 months ago

I had a similar question when doing the analysis:

https://github.com/aristoteleo/dynamo-release/issues/354

hopefully this helps to answer your question.

Rohit

HelloWorldLTY commented 8 months ago

Sounds good, thanks a lot!