Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

taxonomy_table function issue with add_id_column parameter. #191

Closed
grabear opened this issue Dec 17, 2018 · 1 comment
Closed

taxonomy_table function issue with add_id_column parameter. #191

grabear opened this issue Dec 17, 2018 · 1 comment

Comments

@grabear
Copy link
Contributor

@grabear grabear commented Dec 17, 2018

taxonomy_table = function(subset = NULL, value = "taxon_names",

On multiple computers, I've had issues with the taxa::taxonomy_table function not adding the taxon_id column:

> taxonomy_table(metacoder_obj, subset = taxon_ids(metacoder_obj), add_id_col = TRUE)
# A tibble: 175 x 7
   Kingdom  Phylum          Class Order Family Genus Species
   <chr>    <chr>           <chr> <chr> <chr>  <chr> <chr>  
 1 Bacteria NA              NA    NA    NA     NA    NA     
 2 Bacteria Firmicutes      NA    NA    NA     NA    NA     
 3 Bacteria Proteobacteria  NA    NA    NA     NA    NA     
 4 Bacteria Spirochaetae    NA    NA    NA     NA    NA     
 5 Bacteria Verrucomicrobia NA    NA    NA     NA    NA     
 6 Bacteria Bacteroidetes   NA    NA    NA     NA    NA     
 7 Bacteria Fibrobacteres   NA    NA    NA     NA    NA     
 8 Bacteria Actinobacteria  NA    NA    NA     NA    NA     
 9 Bacteria Cyanobacteria   NA    NA    NA     NA    NA     
10 Bacteria Elusimicrobia   NA    NA    NA     NA    NA     
# ... with 165 more rows

However, when I use the function directly linked to the object it works without issue:

> metacoder_obj$taxonomy_table(subset = taxon_ids, add_id_col = TRUE)
# A tibble: 175 x 8
   taxon_id Kingdom  Phylum          Class Order Family Genus Species
 * <chr>    <fct>    <fct>           <fct> <fct> <fct>  <fct> <fct>  
 1 ac       Bacteria NA              NA    NA    NA     NA    NA     
 2 af       Bacteria Firmicutes      NA    NA    NA     NA    NA     
 3 ag       Bacteria Proteobacteria  NA    NA    NA     NA    NA     
 4 ah       Bacteria Spirochaetae    NA    NA    NA     NA    NA     
 5 ai       Bacteria Verrucomicrobia NA    NA    NA     NA    NA     
 6 aj       Bacteria Bacteroidetes   NA    NA    NA     NA    NA     
 7 ak       Bacteria Fibrobacteres   NA    NA    NA     NA    NA     
 8 al       Bacteria Actinobacteria  NA    NA    NA     NA    NA     
 9 an       Bacteria Cyanobacteria   NA    NA    NA     NA    NA     
10 ao       Bacteria Elusimicrobia   NA    NA    NA     NA    NA     
# ... with 165 more rows
@zachary-foster

This comment has been minimized.

Copy link
Collaborator

@zachary-foster zachary-foster commented Dec 17, 2018

Hi @grabear, thanks for the report! I think i fixed it. Feel free to reopen this issue if it is not fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.