ChiLiubio / microeco

An R package for data analysis in microbial community ecology
GNU General Public License v3.0
181 stars 55 forks source link

Error when run t1$cal_diff Error in if (pvalue[k] <= 0.001) sig[k] <- "***" else if (pvalue[k] <= : #Missing values should not be used where TRUE/FALSE values are required #311

Closed xinguo1236 closed 5 months ago

xinguo1236 commented 5 months ago

when I run t1$cal_diff(group = "layer", by_group = "Group", method = "anova")

Error in if (pvalue[k] <= 0.001) sig[k] <- "***" else if (pvalue[k] <= :

Missing values should not be used where TRUE/FALSE values are required

I have already deleted the rows in the OTU table where the row sum is 0, but the error still persists.

Is anything I can do to solve the problem? Many thanks if anyone can help.

ChiLiubio commented 5 months ago

Hi. Could you please save your t1 object and send it me (liuchi0426@126.com) to have a try? To save t1, please use the command save(t1, file = "t1.RData")

xinguo1236 commented 5 months ago

Many thanks for your kind reply. I have already sent the t1 object as an attachment to the email address provided in your message. Thank you for your help.

ChiLiubio commented 5 months ago

Hi. The error comes from the anova for "AA" variable when Group = "LO". Though I have not exactly find the reason how it happened, I add an error checking step in the function to skip the error test and keep on running. I have updated the package in github. Please reinstall it from github and try again.

Best, Chi