Comments (6)
Hi @hoyu310,
The prioritization of ligands by NicheNet (ligand activity analysis) will only occur based on enrichment of their target genes in the set of genes that are differentially expressed in the receiver cell. So there is no prioritization based on the strength of expression of the ligand in the sender cell or strength of expression of the receptor(s) in the receiver cell. Expression in sender cells is only used to determine which ligands are expressed in a sender cell, and expression in receiver cells is used to determine which receptors are expressed in the receiver cell. The default definition of 'being expressed' is that a gene should be expressed in 10% of cells in the cluster of interest. This is not so high (you can put a more stringent cutoff if you want), resulting in the possible outcome that a ligand, top-ranked according to the enrichment of its target genes, is actually not very highly expressed. So what you observe, can be expected based on how NicheNet prioritizes ligands.
However, one thing is weird, based on the results you show me here. That is that ligand X was only found to be important when considering cluster 1 as 'sender' cell type. This is weird because ligand X seems to be expressed in the other clusters as well. So it seems that Ligand X is not specific. Can you check what went possibly wrong here?
from nichenetr.
@browaeysrobin Thanks for the response, now it makes sense why the genes of the ligands or receptors are not always highly expressed.
It is indeed strange that ligand X only has cluster 1 as the sender and cluster 4 as the receiver, now that you pointed it out. After carefully reviewing all the outputs, I now realize why this is the case. For the outputs of nichenet_seuratobj_aggregate, in $ligand_activities, the full set of ligands ("test_ligand"), typically in the hundreds, are included; however, in $ligand_target_matrix and $ligand_receptor_matrix, the target_gene and receptor associations, respectively, are only included for the top 20 ligands listed in $ligand_activities.
For my dataset and the 49 runs, it happened to be that ligand X is a top 20 ligand only in the run of cluster 1 as sender and 4 as receiver. However, when looking back at the outputs, ligand X actually appears in $ligand_activities in most of the 49 runs, with the Pearson_correlation_coefficient_target_gene_prediction_ability of ligand X in a number of these runs being comparable (sometimes even higher) to that of the run of cluster 1 as sender and 4 as receiver - it just happened that in these runs, ligand X is outside of the top 20. The way I compiled the "one table for all the runs" is that for every ligand in $ligand_activities, if the ligand has a target_gene in $ligand_target_matrix and also has a receptor in $ligand_receptor_matrix, then this will be one entry in the compiled table.
Therefore, I think that if there were a parameter in nichenet_seuratobj_aggregate that would allow the computation of $ligand_target_matrix and $ligand_receptor_matrix for all the ligands in $ligand_activities, then it would solve this problem. But I am not sure around how much computational resources this would add to the run and so whether this is feasible, though.
from nichenetr.
Hi @hoyu310 ,
I added a new parameter that allows you to get the output for all ligands (the heatmaps won't look nice, but you can still use the matrices like you do). You should reinstall nichenetr and put filter_top_ligands = FALSE
instead of the default TRUE
as extra parameter. Then you should get all output.
Please let me know whether it works for you now.
Just an extra note on your analysis: in this way it will be hard to find specific sender-receiver interactions if you put the cutoff on expressed genes low. To get some more specific links, you could put this threshold more stringent. What I prefer though is considering all possible sender cells at once in a NicheNet analysis and then tracing back which cell types express which top-ranked ligands most strongly.
from nichenetr.
@browaeysrobin Thanks a lot, I re-installed and ran nichenet_seuratobj_aggregate with filter_top_ligands = FALSE, and it worked! I will also try out your other suggestions. Thanks again.
from nichenetr.
Hi @hoyu310, thanks for the detailed description of your issue.
May I ask for the three metrics for filtering you mentioned: Pearson_correlation_coefficient_target_gene_prediction_ability, Regulatory_potential, and Prior_interaction_potential. What is the difference btw the second and third one?
from nichenetr.
Regulatory_potential: scores in the ligand-target matrix -- used for ligand-target gene regulatory potential
Prior_interaction_potential: weights of the ligand-signaling weighted network -- used for protein-protein interaction evidence, eg between ligands and receptors
See supplementary figure 1 of the paper, or the figure in https://github.com/saeyslab/nichenetr/blob/master/vignettes/model_construction.md, to see what I mean with the ligand-signaling network etc
from nichenetr.
Related Issues (20)
- I can't install nichenet HOT 1
- Condition_colname is not used for subsetting in nichenet_seuratobj_aggregate HOT 2
- `make_line_plot` bugs
- `assign_ligands_to_celltype` bug when there are no general ligands
- Error in `generate_info_tables`
- Warning message in `predict_ligand_activities`
- `generate_prioritization_tables` warnings and documentation
- Error when passing the recorrect_umi argument in get_lfc_celltype HOT 1
- Error in WhichCells.Seurat(object = object, idents = ident.2) : Cannot find the following identities in the object: Adjacent HOT 1
- Error in `Idents<-`: ! 'value' must be a factor or vector HOT 3
- Different results running. the same. code in different version. of HOT 6
- Protein complex HOT 1
- Function generate_info_tables return an error HOT 3
- Low AUPR values in analyses HOT 2
- RankActiveLigands Error
- Can NicheNet be used for analyzing three groups? HOT 1
- Parallelization error when optimizing parameters for NicheNet HOT 3
- How is the Ligand-Target-Matrix generated? HOT 2
- Receiver cells in differential analysis HOT 1
- when sender cell type is only one, HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nichenetr.