# How to use lvm-DE

**URL:** <https://discourse.scverse.org/t/how-to-use-lvm-de/1481>\
**Category:** scvi-tools\
**Tags:** diff-exp\
**Created:** [June 1, 2023, 10:02pm UTC](https://discourse.scverse.org/t/how-to-use-lvm-de/1481 "2023-06-01T22:02:37Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![romainL](https://avatars.discourse-cdn.com/v4/letter/r/94ad74/32.png) [@romainL](https://discourse.scverse.org/u/romainL)\
**Post date:** [June 1, 2023, 10:02pm UTC](https://discourse.scverse.org/t/how-to-use-lvm-de/1481/1 "2023-06-01T22:02:37Z")

</div>

Hi,

I would like to give a try to lvm-DE for my analyses.  
But unfortunately, I couldn’t find documentation neither a function.

Any advice would be appreciated!

Best,  
Romain

---

<div class="post-metadata">

**Author:** ![martinkim0](https://yyz1.discourse-cdn.com/flex035/user_avatar/discourse.scverse.org/martinkim0/32/881_2.png) [@martinkim0](https://discourse.scverse.org/u/martinkim0)\
**Post date:** [June 1, 2023, 11:36pm UTC](https://discourse.scverse.org/t/how-to-use-lvm-de/1481/2 "2023-06-01T23:36:01Z")

</div>

Hi, please see [this thread](https://github.com/scverse/scvi-tools/issues/2059) for more information.

---

<div class="post-metadata">

**Author:** ![romainL](https://avatars.discourse-cdn.com/v4/letter/r/94ad74/32.png) [@romainL](https://discourse.scverse.org/u/romainL)\
**Post date:** [June 2, 2023, 1:31pm UTC](https://discourse.scverse.org/t/how-to-use-lvm-de/1481/3 "2023-06-02T13:31:03Z")

</div>

Thank you for your prompt answer!  
Trying to set up the weight parameter in an into an issue:  
TypeError: get\_bayes\_factors() got an unexpected keyword argument ‘weights’

I am on sci-tools 0.20.3

do you have any idea how I could fix this

I am using this command:

de\_df = model.differential\_expression(  
groupby=“leiden\_scVI”, weights=‘importance’,  
delta=None, fdr\_target=0.01,

)

---

<div class="post-metadata">

**Author:** ![romainL](https://avatars.discourse-cdn.com/v4/letter/r/94ad74/32.png) [@romainL](https://discourse.scverse.org/u/romainL)\
**Post date:** [June 2, 2023, 2:00pm UTC](https://discourse.scverse.org/t/how-to-use-lvm-de/1481/4 "2023-06-02T14:00:32Z")

</div>

So I managed to make it works using the beta version :  
pip install scvi-tools==1.0.0-beta.0 --force-reinstall
