Arcadia-Science / sourmashconsumr

Working with the outputs of sourmash in R
https://arcadia-science.github.io/sourmashconsumr/
Other
21 stars 3 forks source link

create a function to import a sourmash taxonomy annotate file or tibble into a metacoder object #8

Closed taylorreiter closed 1 year ago

taylorreiter commented 1 year ago

This PR creates a function, taxonomy_annotate_to_metacoder() that imports a csv or group of csv files output by sourmash taxonomy annotate or a tibble produced by read_taxonomy_annotate() and generates a metacoder object.

I was sort of sloppy with this PR as I'm learning more about R package development, and went back and fixed some things in the read functions as well -- most of it documentation. Sorry it's all mixed in, I promise to try and be better about separating relevant PRs.

Changes to NAMESPACE and man/* are auto-generated by the devtools::document() command parsing roxygen2 comment headers above functions.

@ctb, @luizirber, and @bluegenes might find this PR interesting.

taylorreiter commented 1 year ago

A question overall I have that can be dealt with later is what are the best practices for somebody else actively testing packages that are in development? Clone the repo and manually run the functions into the environment and then test those functions with the provided test data?

That's a great question. I don't actually know the correct answer, but I added dev/test instructions to a different repository that basically documents a test env and states how to run the tests from the command line. I'll add something like this here when I tackle adding CI via github actions, which I'm hoping to do soon ish!