ropensci / taxa

taxonomic classes for R
https://docs.ropensci.org/taxa
Other
48 stars 12 forks source link

Make `recursive` options in `subtaxa` and `supertaxa` accept a number #34

Closed zachary-foster closed 7 years ago

zachary-foster commented 7 years ago

This would allow for specifying the number of recursions to do. TRUE/FALSE could still be accepted. FALSE = 1.

This was an issue in the metacoder repo:

https://github.com/grunwaldlab/metacoder/issues/116

zachary-foster commented 7 years ago

Also, this should be carried over to filter_taxa and any other functions that have a subtaxa = TRUE type option. So filter_taxa(data, x == y, subtaxa = 2) would return all selected taxa and subtaxa one rank down by calling subtaxa(data, x == y, recursive = 2).