Oddly Specific

A Blog About Data Science and Reproducible Research

Acetaminophen and Reflective vs. Reflexive Learning

Analysis narrative with R code for reproducing results

This post documents the key analyses reported in the article “Acetaminophen Enhances the Reflective Learning Process” by Rahel Pearson, Seth Koslov, Bethany Hamilton, Jason Shumake, Charles S. Carver, and Christopher G. Beevers. It is written from my perspective as a co-author who was not involved in designing or conducting the study but was consulted after it was finished to help with the data analysis.

When 0.1 + 0.2 Does Not Equal 0.3

Rewriting R's %in% operator to match floating point values

I explain the dangers of using == and R’s %in% operator with decimal values and how dplyr::near can be used instead of ==. I also show how to overload the %in% operator to perform safe approximate matching of numeric vectors.

Everything You Know about the P-Value is Wrong

Yet another post tut-tutting the misuse of p-values

If you want to read my version of the p-value sermon, check out this post I wrote for the tl;dr pharmacy blog.