Eric Leung
erictleung.bsky.social
Eric Leung
@erictleung.bsky.social
marketing data scientist, generalist, math and library enthusiast, data scientist of the third kind, loves good stationary and pens, low tech enthusiast, open source tinkerer, opinions = mine #rstats
Pinned
hello world!

lil about me, I'm a former computational biologist, working as a data scientist in media and entertainment marketing, and I like getting better at my tools and share those learnings.

I also love good stationary and fountain pens.
"Plaintext World"

"Quality lo-fi sites for an internet that doesn't suck."

plaintextworld.com
Plaintext World
A collecton of plaintext (and mainly text) websites. Welcome to the lo-fi web.
plaintextworld.com
November 18, 2025 at 9:50 PM
politics aside, it's pretty amazing to find high quality data visualizations for free on the Wikipedia page for the recent NYC mayoral election. and using a clever ternary plot to represent the breakdown of votes for three candidates in one color

en.wikipedia.org/wiki/2025_Ne...
November 5, 2025 at 6:37 PM
recently learned the sQuote() and dQuote() R functions

> cat("distinguish plain", sQuote("single"), "and", dQuote("double"), "quotes")
distinguish plain ‘single’ and “double” quotes
> cat("distinguish between 'single' and \"double\" quotes")
distinguish between 'single' and "double" quotes

#RStats
October 6, 2025 at 7:54 PM
for fans of mcelreath's statistical rethinking book, it now has a wikipedia page en.wikipedia.org/wiki/Statist...
Statistical Rethinking - Wikipedia
en.wikipedia.org
September 26, 2025 at 3:54 PM
thought I understood f-strings enough, untill I took this lil quiz. humbled me real quick fstrings.wtf
fstrings.wtf
August 6, 2025 at 1:31 PM
Reposted by Eric Leung
If you ask me for advice, the answer I give you will almost always be to reach out and talk to people. Not to read blog posts or watch youtube videos, though those are wonderful resources, but to meet with & talk to actual humans. It's not easy, and it takes time and effort, but it's the way #databs
July 25, 2025 at 8:44 PM
been using forest sounds in the background for work. it's been quite peaceful

www.tree.fm
tree.fm – Tune Into Forests From Around The World 🌳🔈
People around the world recorded the sounds of their forests, so you can escape into nature, while in lockdown or unable to travel. Use this site to chill, meditate or do some digital shinrin-yoku.
www.tree.fm
July 24, 2025 at 2:47 PM
TIL you can make an R Jupyter notebook in Google Colab with this link colab.research.google.com/notebook#cre...
Google Colab
colab.research.google.com
July 24, 2025 at 3:59 AM
been dragging my feet on organizing my digital folders after finally finding this framework for organizing your digital.

in theory, i really like it. but with any digital cleaning, easier said than done.

anyone else have other systems they use to organize your life?

johnnydecimal.com
A system to organise your life
Johnny.Decimal is a system to organise your life. Find things, quickly, with more confidence, and less stress. It's free to use and the concepts are the same at home or work.
johnnydecimal.com
July 21, 2025 at 7:29 PM
i've been writing sql code for a while now, but yesterday i learned the acronym CTAS, which stands for "create table as select"
July 17, 2025 at 7:11 PM
been trying to get into using vscode a bit more, and had some of the keyboard shortcuts interfere with each other.

took me a bit to figure it out, but in case anyone else is having issues with it, go to File > Preferences > Keyboard Shortcuts menu

code.visualstudio.com/docs/configu...
Keyboard shortcuts for Visual Studio Code
Here you will find the complete list of keyboard shortcuts for Visual Studio Code and how to change them.
code.visualstudio.com
July 17, 2025 at 7:10 PM
turns out, tryCatch() in R is locally scoped, so if you need to change any variables, you'll need to make it more explicit with something like

assign("var_i_need_to_change", "change_to_this_value", env = globalenv())

stackoverflow.com/a/48391135/2...
tryCatch block in R, change value of outer variable
Here is my code. It produces infinite loop, because value of something variable does not change within captured error. Is it supposed to be this way? How can I fix it so that value of something cha...
stackoverflow.com
July 17, 2025 at 6:50 PM
Reposted by Eric Leung
The #dataBS (Data Behind the Scenes) Conference Call for speakers is out! We're gonna do this!!

All online, single track, free to attend. Come talk about your messy experiences doing data stuff. At work, personal projects, whatever. A space to commiserate about nerdy things!

bit.ly/dataBSconf-cfs
Data Behind the Scenes Conf - Call for Speakers
What This Conference Is About "Data, Behind the Scenes" is a (free) online-only, single track conference centered on the real stories of data work from the folks in the trenches. We’re not here for th...
bit.ly
July 1, 2025 at 2:47 PM
Reposted by Eric Leung
So freaking excited to have Cat Hicks on the Hangout tomorrow. She's keynoting at posit conf, too ✨ Go register and I'll see you there!! #databs

Event:
Posit Data Science Hangout with Cat Hicks
Thursday June 26th 2025 at 12PM Eastern/9am Pacific
Register for the Hangout event series at pos.it/dsh
June 25, 2025 at 10:28 PM
better to over communicate than assume when working across teams
June 25, 2025 at 10:51 PM
TIL about ggmosaic, an R package for visualizing categorical data haleyjeppson.github.io/ggmosaic/ind...
Mosaic Plots in the ggplot2 Framework
Mosaic plots in the ggplot2 framework. Mosaic plot functionality is provided in a single ggplot2 layer by calling the geom mosaic.
haleyjeppson.github.io
May 20, 2025 at 2:14 AM
i spent a whole day trying to get 5 lines of code to run properly. never have i had such a sigh of relief that it finally worked
May 7, 2025 at 10:24 PM
pretty cool that the new york public library has some of their engineering practices up on GitHub github.com/NYPL/enginee...
GitHub - NYPL/engineering-general: Standards, values, and other information relevant to the NYPL Engineering Team.
Standards, values, and other information relevant to the NYPL Engineering Team. - NYPL/engineering-general
github.com
May 2, 2025 at 10:58 PM
woah, when did RStudio gain this functionality that when you wait for autocomplete to finish, it'll show you a preview of that data object that it is suggesting in the autocomplete?? #RStats
May 2, 2025 at 4:35 PM
is there a way to use sparklyr spark data frames work with recipes from tidymodels? I saw that sparklyr has its own workflow transformation functions, but the variety of functions doesn't seem to be parity (yet) #RStats
April 29, 2025 at 11:07 PM
i made a gif of how the cherry blossoms at the brooklyn botanical garden are doing. the past couple of days have been exciting!
April 24, 2025 at 8:16 PM
in R, I wanted to split out a value by a separator, so separate_wider_delim comes to mind tidyr.tidyverse.org/reference/se.... but then i realized that my delim of an underscore appears all throughout my value. so I ended up using str_extract() with some regex stringr.tidyverse.org/reference/st...
April 23, 2025 at 2:51 PM
Reposted by Eric Leung
Biggest commitment to a 3 second joke I've ever seen
April 9, 2025 at 6:33 AM
dang, didn't realize how long it's been since i've updated my conda version. twenty plus versions seems like a lot 😂
April 8, 2025 at 8:40 PM