Brute force building a kmer database in R - what could go wrong? (CC272)
Channel: Riffomonas Project
Date: 2024-04-08

Pat attempts to put together the R code that he's been writing to create a single function that will build a kmer database. Along the way, Pat continues to use Test Driven Development using the testthat R package and a number of tools from base R. After making sure everything works by TDD, he attempts to build the database with the most recent version of the RDP training set. This episode is part of an ongoing effort to develop an R package that implements the naive Bayesian classifier.

If you want to get a physical copy of R Packages: https://amzn.to/43pMR8L
If you want a free, online version of R packages: https://r-pkgs.org/

You can find my blog post for this episode at https://www.riffomonas.org/code_club/2024-04-08-kmer-database.

Check out the GitHub repository at the:
* Beginning of the episode: https://github.com/riffomonas/phylotyper/tree/6d206f9d22969a9654ff1eb279343fe2d8740fb6
* End of the episode: https://github.com/riffomonas/phylotyper/tree/cdfa2cde961ad1b6e7ef987b90ca52beb0f6526e


#rdp #16S #classification #classifier #microbialecology #microbiome

Support Riffomonas by becoming a Patreon member!
https://www.patreon.com/riffomonas

Want more practice on the concepts covered in Code Club? You can sign up for my weekly newsletter at https://shop.riffomonas.org/youtube to get practice problems, tips, and insights.

If you're interested in purchasing a video workshop be sure to check out https://riffomonas.org/workshops/

You can also find complete tutorials for learning R with the tidyverse using...
Microbial ecology data: https://www.riffomonas.org/minimalR/
General data: https://www.riffomonas.org/generalR/

0:00 Introduction
3:15 Write test for function to generate database
9:03 Write function to generate database
12:23 Write tests and functions to convert between genera and indices
20:24 Evaluate function with full database

3:52 Playlist
20:44 https://mothur.org/wiki/rdp_reference_files/