With dplyr version 1.0, there are new ways that you can write functions

The programming with dplyr vignette with the docs is the best reference if you’re new to R…but if you’re not, let’s see how to upgrade your programming from the old ways.

If you’re familiar with using sym and converting from standard to nonstandard form, the following progression should show you…

Use all of the cool examples with your own data, while keeping that data local or inside your network.

If you haven’t heard of it, Observable is a platform for interactive coding brought to the world by Mike Bostock, creator of d3. It embodies a bold vision of reactive programming from Bret Victor and frankly, I think it’s cool as hell. One drawback: I’m not best at Javascript, the…

I really enjoyed your post, very helpful.

One thing that is potentially confusing is that some of the data.table operations you show work in-place, and the dplyr ones don't. For (4), as an example, to make them equivalent you actually would have to do this:

data = data[, !c(“PAID.IN.EURO”)] #datatable

data[, PAID.IN.EURO:= NULL] #datatable (alternative way)

data %<>% select(-PAID.IN.EURO) #dplyr

For the first datatable way, it's not in place so we need to assign back to "data", the second one does work in-place, and for dplyr, I use the magrittr in place assignment. (You could also do data = data %>% select(...) or data = select(data, ...)).

How to use pyenv’s Python to satisfy Homebrew dependencies so only pyenv manages Python 3 installations on your machine

Like many data scientists and Python developers before me, I’ve given up on managing my own Python builds and turned to pyenv (links to chronological posts in Towards Data Science). At various points in time, I built Python versions from source myself or used the prebuilt Framework installers on OSX…

Great Expectations is a useful tool in any data pipeline to ensure that data is what you expect. While data validation and such have been compared to Data Science’s “janitorial work”, others argue that it’s really part of the analysis. Either way, I’ve had enough headaches with analysis being wrong…

Andy Reagan

Father, Lead Data Scientist at MassMutual, occasional runner.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store