I have over 100 textfiles that contain BLAST hit results for each contig in that sample. The format includes taxids. I have opened these textfiles into R tidyverse for some data manipulation, but the first thing I really want to get are the domains/kingdoms for each species. For example, contig-1 top hit was a bacteria and it's taxid was 343509. I'd want to create a new column that adds "Bacteria" to it, and possibly also later on get the "Family" and "Genus" level names for the species.
Is there an R package that can look at a species name or taxid and output such information easily which I can then add into my tibble?
The R taxa package doesn't seem to be what I want, as it focuses on creating your own taxonomy definitions using taxids, but I was hoping for something that would do it automatically since I have hundreds of files to go through.
I think you'll end up having to mess around with the
rentrezpackage for this. But the
taxonomizrmight be the more appropriate approach here. I'd try that first.
I tried taxonomizr...had no clue what the sql node table was supposed to be or how to even make one.