# Warning message in Maaslin2

**URL:** <https://forum.biobakery.org/t/warning-message-in-maaslin2/2537>\
**Category:** MaAsLin\
**Created:** [August 31, 2021, 2:58pm UTC](https://forum.biobakery.org/t/warning-message-in-maaslin2/2537 "2021-08-31T14:58:33Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ayuhhh](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/ayuhhh/32/993_2.png) [@ayuhhh](https://forum.biobakery.org/u/ayuhhh)\
**Post date:** [August 31, 2021, 2:58pm UTC](https://forum.biobakery.org/t/warning-message-in-maaslin2/2537/1 "2021-08-31T14:58:33Z")

</div>

Hi,

First, Maaslin2 is a really really wonderful tool!

I am running an analysis with one predictor of interest and 7 categorical covariates. I’ve run maaslin2 (lm analysis method, “AST” transformation, min prevalence and abundance thresholds to filter out rare features), and a warning message comes along with the output, saying “Warning message: In var(if (is.vector(x) || is.factor(x)) x else as.double(x), na.rm = na.rm) : Calling var(x) on a factor x is deprecated and will become an error.” what would be the possible causes?

Thank you!  
Yuhan

---

<div class="post-metadata">

**Author:** ![Kelsey\_Thompson](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/kelsey_thompson/32/65_2.png) [@Kelsey\_Thompson](https://forum.biobakery.org/u/Kelsey_Thompson)\
**Post date:** [September 2, 2021, 12:57pm UTC](https://forum.biobakery.org/t/warning-message-in-maaslin2/2537/2 "2021-09-02T12:57:33Z")

</div>

Hi @ayuhhh,

Thank you for your feedback. This warning looks like it is letting us know that soon the way we phrased something in the source code will no longer work. I will add this to our development document for a patch in the next release. Thank you for sharing it with us. I do not believe that this will change anything about how MaAsLin is currently running… but if you want to share your data (or a minimally reproducible/blinded dataset) I am happy to take a closer look.

Best,  
Kelsey

---

<div class="post-metadata">

**Author:** ![ayuhhh](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.biobakery.org/ayuhhh/32/993_2.png) [@ayuhhh](https://forum.biobakery.org/u/ayuhhh)\
**Post date:** [September 4, 2021, 3:34pm UTC](https://forum.biobakery.org/t/warning-message-in-maaslin2/2537/3 "2021-09-04T15:34:47Z")

</div>

Thanks for your reply. My R code for the Maaslin analysis was as follows:

fit\_data ← Maaslin2(  
input\_data1, input\_metadata1,‘demo\_output’, transform = “AST”,  
max\_significance = 0.1,  
fixed\_effects = c(“status”),  
normalization = ‘NONE’,  
reference = c(‘status,HC’))

and the input\_data file and the input\_metadata file were attached.[input\_data.csv](https://forum.biobakery.org/uploads/short-url/3agfetBBy63THO0gPJ4qnCJOeXb.csv) (627.3 KB)  
[input\_metadata.csv](https://forum.biobakery.org/uploads/short-url/8ndjyvGWWjveaYZO3Jbp9zunufQ.csv) (852 Bytes)

Looking forward to your reply. Thanks!
