Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sc.tl.rank_genes_groups , p value question #114

Open
ruiqiizhou opened this issue Jan 21, 2024 · 1 comment
Open

sc.tl.rank_genes_groups , p value question #114

ruiqiizhou opened this issue Jan 21, 2024 · 1 comment

Comments

@ruiqiizhou
Copy link

When I use function sc.tl.rank_genes_groups(adata, 'Cell Type', method='wilcoxon', pts = True,tie_correct = True) , 'Cell Type' only contains 2 groups, I want to check adjusted p values, then I use pd.DataFrame(adata.uns['rank_genes_groups']['pvals_adj']).
It gave me 2 different columns adjusted p values. I am not sure how can I interpret these two different p values. I just wanna use p value to check interested genes differential expression in two groups. In which group is this gene expressed more significantly?
Which value I should trust?

@LuckyMD
Copy link
Contributor

LuckyMD commented Jan 22, 2024

Hi @ruiqiizhou,

Are the p-values in both different? If you have 2 cell types and you use a general sc.tl.rank_genes_groups call, then it test cell type A vs cell type B, and cell type B vs cell type A. It's set up this way as it always tests A vs rest, B vs rest, etc. That should result in p-values for both sides of the test. They should thus be the same. If not, maybe this question is best asked on the scanpy github at scverse.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants