# Marker gene selection: rank\_marker\_genes vs diffxpy

**URL:** <https://discourse.scverse.org/t/marker-gene-selection-rank-marker-genes-vs-diffxpy/935>\
**Category:** scanpy\
**Tags:** diff-exp\
**Created:** [November 17, 2022, 5:20pm UTC](https://discourse.scverse.org/t/marker-gene-selection-rank-marker-genes-vs-diffxpy/935 "2022-11-17T17:20:27Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![auesro](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/auesro/32/216_2.png) [@auesro](https://discourse.scverse.org/u/auesro)\
**Post date:** [November 17, 2022, 5:20pm UTC](https://discourse.scverse.org/t/marker-gene-selection-rank-marker-genes-vs-diffxpy/935/1 "2022-11-17T17:20:27Z")

</div>

Dear community,

I have a snRNAseq dataset of 4 samples and 2 conditions (2 samples per condition). The experimental samples differ from the control ones in that some cell types have lower numbers due to an specific genetic ablation approach.

Now I want to identify marker genes for the cell types identified in my dataset and I face 2 options according to what I have read:  
-Use scanpy rank\_gene\_groups, considered only good for exploratory analysis according to scanpy authors  
-Use diffxpy, a much more powerful tool

Given this introduction, it would be obvious to go for diffxpy, however my impression is diffxpy is more geared towards hardcore differential expression between conditions rather than marker gene selection between cell clusters…now my question is: am I wrong? Can I use diffxpy for marker gene selection? If yes, how? what would be the test to run in diffxpy?

Thanks!

A
