KasperSkytte / ampvis2

Tools for visualising microbial community amplicon data
https://kasperskytte.github.io/ampvis2/
GNU General Public License v3.0
66 stars 23 forks source link

Problem with mothur biom file #100

Closed Cupplesam closed 3 years ago

Cupplesam commented 3 years ago

I am having trouble using the following command with my mothur biom file. The error message is below. Any suggestions would be appreciated, thanks so much for your time.

amp_import_biom(file)

Error: Can't combine ..1$Kingdom and ..2$Kingdom <factor<01553>>. Run rlang::last_error() to see where the error occurred. In addition: Warning message: Taxonomy had less than 7 levels for all OTU's (Kingdom->Species), filling with NA from Species level and up.

KasperSkytte commented 3 years ago

Hi

Please provide a reproducible example.

welinda1 commented 3 years ago

I have the same issue for a while! I can no longer import biom files that used to work. I suspect that the problem was caused by updates because I can't use it since the installations. Found a similar problem reported on GitHub : https://github.com/knausb/vcfR/issues/159 https://github.com/knausb/vcfR/issues/159#issuecomment-636526057 that was traced back to R and dplyr updates in spring.

Error: Can't combine ..1$Kingdom and ..2$Kingdom . Run rlang::last_error() to see where the error occurred. In addition: Warning message: Taxonomy had less than 7 levels for all OTU's (Kingdom->Species), filling with NA from Species level and up.

rlang::last_error() <error/vctrs_error_incompatible_type> Can't combine ..1$Kingdom and ..2$Kingdom . Backtrace:

  1. ampvis2::amp_import_biom("mypath/myfile.biom")
  2. vctrs::vec_default_ptype2(...)
  3. vctrs::stop_incompatible_type(...)
  4. vctrs:::stop_incompatible(...)
  5. vctrs:::stop_vctrs(...) Run rlang::last_trace() to see the full context. rlang::last_trace() <error/vctrs_error_incompatible_type> Can't combine ..1$Kingdom and ..2$Kingdom . Backtrace: x
  6. +-ampvis2::amp_import_biom("mypath/myfile.biom")
  7. | -dplyr::bind_rows(taxSkeleton, tax)
  8. | -vctrs::vec_rbind(!!!dots, .names_to = .id)
  9. -vctrs::vec_default_ptype2(...)
  10. -vctrs::stop_incompatible_type(...)
  11. -vctrs:::stop_incompatible(...)
  12. -vctrs:::stop_vctrs(...)
KasperSkytte commented 3 years ago

I think I would need your exact biom file or a subset thereof for debugging, I cannot reproduce the error on my end.

KasperSkytte commented 3 years ago

Hi

The issue should now be fixed. Please see #113