Programming/R

[R/Error] microbiomeMarker패키지 의 run_lefse실행 시 Error in check_rank_names(ps) 에러

김해김씨99대손 2023. 4. 28. 11:19

| Error

Error in check_rank_names(ps) : 
  ranks of taxonimic profile must be one of Kingdom, Phylum, Class, Order, Family, Genus, Species

 

 

| Error 해결

phyloseq::rank_names(your_ps)

위 문구로 현재 본인의 phyloseq개체가 어떤 tax rank를 가지고 있는지 판단하자. 

단순히 여기서 Kingdom, Phylum, Class, Order, Family, Genus, Species외의 추가적인 rank가 있다면 삭제하면 된다. 

 

TAX<- tax_table(your_ps) %>% data.frame()
tax_table(your_ps) <- tax_table(as.matrix(TAX[,c("Kingdom", "Phylum", "Class", "Order", "Family", "Genus", "Species")]))

rank_names(your_ps)

 

 

 

 

| 참고

- https://github.com/yiluheihei/microbiomeMarker/issues/26

반응형