Lorenzo Gaborini's Avatar

Lorenzo Gaborini

@lgaborini

Lausanne based ๐Ÿ‡จ๐Ÿ‡ญ - Senior Data Analyst @IntTestAgency - PhD Forensic Science @unil - MSc Mathematical Engineering @polimi ยฎ๐Ÿ๐Ÿƒโ€โ™€๏ธโ›ท๐Ÿšฒ๐Ÿฅ๐Ÿฝ

28
Followers
102
Following
59
Posts
25.12.2023
Joined
Posts Following

Latest posts by Lorenzo Gaborini @lgaborini

Live, laugh, lapply

07.03.2026 15:25 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

Until they decide that giving you admin permissions, API keys, cloud infrastructure etc. is too much for your role

26.02.2026 06:25 ๐Ÿ‘ 2 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

A wild `separate_wider_delim()` appears ๐Ÿ™Œ

10.02.2026 14:22 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

I agree, not to mention English not being one's own L1 (and I'm willing to bet there are even differences among native speakers)

31.01.2026 19:45 ๐Ÿ‘ 0 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

Normally load_all() is enough to load the dev help (very rarely it doesn't refresh). Is the .Rd there? Maybe try reloading the session?

30.01.2026 14:25 ๐Ÿ‘ 0 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

The different time scales are really misleading.
Cycling seems to be most protective at 2 METยทhours per week.
At a light commuting pace (MET=4), this is 30 minutes per week (5 minutes per day). You do not even warm up! And zero benefits at 10 METยทhours per week (2.5 hours per week).

22.01.2026 09:39 ๐Ÿ‘ 0 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Post image

Yes, I had the habit to click on the active icon without using the keyboard
But I like the new position, I'll get used to it!

14.01.2026 07:47 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

But then you can't hide the activity bar by clicking on the active tab :(

13.01.2026 10:21 ๐Ÿ‘ 0 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0

Honestly I've never had issues using R + RStudio on Windows: this as long as you have RTools installed, and you're not installing non-CRAN packages that require compilation

01.01.2026 08:45 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

What's different? The backend (knitr/pandoc) is the same, and you should also be able to change the HTML template in case it lacks metadata. Or maybe also writing a Lua filter to preprocess your Qmd for those extreme cases...

06.12.2025 17:00 ๐Ÿ‘ 0 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0

Not that new, but I'd say ggiraph: it's magic! It takes a ggplot2 and adds SVG + Shiny interactivity to the grobs almost for free. If only there were some extension mechanism...

05.12.2025 18:44 ๐Ÿ‘ 2 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0

Will it just become `verse`?

23.11.2025 22:50 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 1

Yes officially with the recent {quarto} package:
cran.r-project.org/web/packages...

And unofficially you can use that syntax under knitr. (And the !expr syntax in code chunk options.)

23.11.2025 14:49 ๐Ÿ‘ 5 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 1

Wow! Yet another awesome tool with Rust-awesomeness โœจ it's SO pleasant to work in a snappy environment!

21.11.2025 08:39 ๐Ÿ‘ 2 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

I have a dream: template strings in base R!

17.11.2025 17:13 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

Just explicitly call utils::data(), do not prefix yours

07.11.2025 06:18 ๐Ÿ‘ 2 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0

I can move the .venv outside (UV_PROJECT_ENVIRONMENT) but this is not standard and not well recognized by Positron.

05.11.2025 22:23 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

uv is generally fine (new releases take a while to get whitelisted โ€” same as Positron, ark, ...). But most other packages are dead: dbt, airflow, flask, csvkit, pip, sometimes Python. (Plus Onedrive doesn't support symlinks, the .venv gets actually filled by the library.)

05.11.2025 22:23 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0

Still, Python ships lots of executables, and Windows Defender is not happy. So uv is still unusable since I can't add an exception for each project. And the maintainer refuses to use a centralized library: {renv} does it better!

05.11.2025 14:06 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 2 ๐Ÿ“Œ 0

I'm increasingly proud to have written and published things before LLMs existed.

01.11.2025 11:55 ๐Ÿ‘ 88 ๐Ÿ” 6 ๐Ÿ’ฌ 5 ๐Ÿ“Œ 0
Preview
Layers have names by teunbrand ยท Pull Request #5967 ยท tidyverse/ggplot2 This PR aims to fix #4066. Briefly, it sets names for the layers part of a plot that should be able to uniquely identify a layer. They're specified in the params argument to layer() and default...

5. Layers can have names
github.com/tidyverse/gg...

03.11.2025 10:06 ๐Ÿ‘ 4 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0
Preview
Label dictionary by teunbrand ยท Pull Request #6077 ยท tidyverse/ggplot2 This PR aims to fix #5178. Briefly, it adds labs(dict) that allows one to use a data-dictionary to label a plot based on variable names (rather than aesthetics). Let's just jump into examples. ...

4. New argument labs(dictionary) to label based on variable name rather than based on aesthetic (@teunbrand, #5178)

AKA: more awesomeness just like scales::label_dictionary()!
github.com/tidyverse/gg...

03.11.2025 10:06 ๐Ÿ‘ 2 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0
Preview
Layer parameter controlling facet layout by teunbrand ยท Pull Request #6336 ยท tidyverse/ggplot2 This PR aims to (eventually) fix #3062. Briefly, it adds a layer(layout) argument to control how data is assigned to panels. Currently only layout = "fixed" is implemented, which repeats ...

3. New layer(layout) argument to interact with facets (@teunbrand, #3062)

AKA: repeat a layer in every facet without messing with data
github.com/tidyverse/gg...

03.11.2025 10:06 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0
Preview
Manual stat by teunbrand ยท Pull Request #6103 ยท tidyverse/ggplot2 This PR aims to fix #3501 and replaces #6066. It improves upon #6066 by simplifying the stat to stat_manual(fun = identity). It really is a thin wrapper to essentially offer a way for a user to pro...

2. New stat: stat_manual() for arbitrary computations (@teunbrand, #3501)
github.com/tidyverse/gg...

03.11.2025 10:06 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0
Preview
Repurpose coord expansion by teunbrand ยท Pull Request #6027 ยท tidyverse/ggplot2 This PR aims to fix #6020. Briefly, it allows expand to take a length-4 logical vector for each of the positions (top, right, bottom, left). Alternatively, one could use a named vector too. devtool...

1. coord_*(expand) can now take a logical vector to control expansion at any side of the panel (top, right, bottom, left)
github.com/tidyverse/gg...

03.11.2025 10:06 ๐Ÿ‘ 3 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0

My top 5 ggplot2 4.0.0 updates (well hidden in the NEWS) and their usage: #rstats (there's so much to unpack!) ๐Ÿ™Œ

03.11.2025 10:06 ๐Ÿ‘ 6 ๐Ÿ” 2 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0

Luckily it's getting less and less necessary in R, empty arguments (trailing commas) are often supported within the tidyverse ๐Ÿป
And also in DuckDB SQL FYI

22.10.2025 12:10 ๐Ÿ‘ 2 ๐Ÿ” 0 ๐Ÿ’ฌ 1 ๐Ÿ“Œ 0

Without leaving the tidyverse, just extract the numbers with readr::parse_number(), then use order() on the string:

Treatment <- c("Control", "Asprin 10mg/day", "Asprin 50mg/day", "Asprin 100mg/day", "Acetomycin 100mg/day" "Acetomycin 1000mg/day")

Treatment[order(readr::parse_number(Treatment))]

02.10.2025 08:37 ๐Ÿ‘ 2 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

ggplot2 and now plumber2! What a year! ๐Ÿ™Œ

24.09.2025 12:53 ๐Ÿ‘ 1 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0

It is like saying that I know how to fix a faucet because I can call a plumber

22.09.2025 07:51 ๐Ÿ‘ 2 ๐Ÿ” 0 ๐Ÿ’ฌ 0 ๐Ÿ“Œ 0