Thom Volker's Avatar

Thom Volker

@thomvolker.bsky.social

PhD Candidate in Statistics, Utrecht University Creates fake data for a living. thomvolker.github.io

215 Followers  |  227 Following  |  329 Posts  |  Joined: 17.02.2025  |  2.4319

Latest posts by thomvolker.bsky.social on Bluesky

Image of R code. To reproduce:

library(ggplot2)
library(dplyr)

library(mice, warn.conflicts = FALSE)
 
imp <- mice(nhanes, m = 5, maxit = 5, seed = 1, 
            ignore = rep(c(FALSE, TRUE), c(20, 5)), 
            print = FALSE)
 
impdats <- complete(imp, "all")
 
train <- lapply(impdats, function(dat) subset(dat, !imp$ignore))
test <- lapply(impdats, function(dat) subset(dat, imp$ignore))
 
fits <- lapply(train, function(dat) lm(age ~ bmi + hyp + chl, data = dat))
preds <- predict_mi(object = fits, newdata = test, pool = TRUE, interval = "prediction")
 
preds
 
preds %>% 
  as.data.frame() %>% 
  mutate(case = 1:nrow(preds),
         y = test[[1]]$age) %>% 
  ggplot(aes(x = fit, y = case, col = rowSums(is.na(nhanes[imp$ignore,]))>0)) +
  geom_point() +
  geom_errorbar(aes(xmin = lwr, xmax = upr)) +
  theme_minimal() +
  scale_color_manual(values = mice::mdc(1:2), labels = c("observed", "missing")) +
  theme(legend.title = element_blank(),
        legend.position = "bottom") +
  labs(x = "prediction",
       title = "Pooled prediction intervals")

Image of R code. To reproduce: library(ggplot2) library(dplyr) library(mice, warn.conflicts = FALSE) imp <- mice(nhanes, m = 5, maxit = 5, seed = 1, ignore = rep(c(FALSE, TRUE), c(20, 5)), print = FALSE) impdats <- complete(imp, "all") train <- lapply(impdats, function(dat) subset(dat, !imp$ignore)) test <- lapply(impdats, function(dat) subset(dat, imp$ignore)) fits <- lapply(train, function(dat) lm(age ~ bmi + hyp + chl, data = dat)) preds <- predict_mi(object = fits, newdata = test, pool = TRUE, interval = "prediction") preds preds %>% as.data.frame() %>% mutate(case = 1:nrow(preds), y = test[[1]]$age) %>% ggplot(aes(x = fit, y = case, col = rowSums(is.na(nhanes[imp$ignore,]))>0)) + geom_point() + geom_errorbar(aes(xmin = lwr, xmax = upr)) + theme_minimal() + scale_color_manual(values = mice::mdc(1:2), labels = c("observed", "missing")) + theme(legend.title = element_blank(), legend.position = "bottom") + labs(x = "prediction", title = "Pooled prediction intervals")

Cool stuff!

Florian van Leeuwen and I implemented a prediction function in the #mice package that allows the incorporation of missing data uncertainty in a prediction interval.

The `predict_mi()` function is available in the current development version: github.com/amices/mice

#Rstats #statsky

29.09.2025 13:32 β€” πŸ‘ 17    πŸ” 3    πŸ’¬ 2    πŸ“Œ 0
Preview
Politici weten niet meer hoe het heurt. Ruud Koole pleit voor β€˜constitutionele geletterdheid’ Politici lijken zelf niet meer te snappen hoe de parlementaire democratie werkt, betoogt Ruud Koole. Dinsdagavond houdt de politicoloog β€˜een pleidooi voor historisch institutioneel besef en constituti...

Politici lijken zelf niet meer te snappen hoe de parlementaire democratie werkt, betoogt Ruud Koole. Vanavond houdt de politicoloog β€˜een pleidooi voor historisch institutioneel besef en constitutionele geletterdheid’.
www.mareonline.nl/achtergrond/...

07.10.2025 10:00 β€” πŸ‘ 37    πŸ” 18    πŸ’¬ 1    πŸ“Œ 2

Looking forward to talking about our work on the value of explanation for decision-making at this workshop

07.10.2025 14:32 β€” πŸ‘ 8    πŸ” 1    πŸ’¬ 0    πŸ“Œ 0

Both can hold simultaneously? But it's Dutch indeed!

07.10.2025 14:14 β€” πŸ‘ 2    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

"emerging literature" == i presented once at a conference
"recent research" == two papers and one blog post
"research tradition" == everything in my zotero folder
At least, that's what I was told

07.10.2025 13:12 β€” πŸ‘ 17    πŸ” 5    πŸ’¬ 1    πŸ“Œ 0

For all things related to R, I find it as intuitive as RStudio, with the addition that it's very easy to mix in python when needed. There are quite some handy tricks implemented, like the thing with color codes or creating github issues from "TODO"s in markdown in a single click.

07.10.2025 13:28 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0

Click on the title of the picker and it’ll switch between hex, RGB, and HSL!

06.10.2025 23:28 β€” πŸ‘ 5    πŸ” 2    πŸ’¬ 0    πŸ“Œ 0
Post image

How cool is this?! Positron opens a HTML color picker when typing a HTML color in your script.

#RStats #dataviz

06.10.2025 20:16 β€” πŸ‘ 37    πŸ” 6    πŸ’¬ 2    πŸ“Œ 0
Post image

β€œLittered with errors including three nonexistent academic references and a made-up quote from a Federal Court judgement.”

Deloitte issues refund to (Aus) government for using AI in $440k report

06.10.2025 09:21 β€” πŸ‘ 23    πŸ” 11    πŸ’¬ 0    πŸ“Œ 0

No pets for you I guess?

06.10.2025 19:11 β€” πŸ‘ 5    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0

Die gelijkenis is inderdaad treffend!

06.10.2025 18:29 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

DOGE got nothing on this.

06.10.2025 18:19 β€” πŸ‘ 2    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

Ja, ik denk dat dat, verdrietig genoeg, inderdaad is wat veel mannen willen. Het onderstaande fragment maakt een vergelijkbaar punt. Bizar dat de emancipatie eerder achteruit gaat dan verbetert.

06.10.2025 18:15 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 2    πŸ“Œ 0
Post image

Meneer die denkt dat iedereen z'n profielfoto in hoge resolutie wilt om boven hun bed te hangen noemt 250.000 andere mensen een narcist.

05.10.2025 22:28 β€” πŸ‘ 214    πŸ” 22    πŸ’¬ 28    πŸ“Œ 8

Ik vraag me altijd vooral af of deze mannen een partner willen of een soort assistent die het huishouden runt

06.10.2025 17:52 β€” πŸ‘ 2    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0
Video thumbnail

Wij zΓ©ggen niet alleen dat we wonen prioriteit maken, we investeren er groot in.

We nemen het heft in eigen hand, doorbreken de stilstand en we gaan bouwen voor de sociale meerderheid.

We hebben dit eerder gedaan. En we kunnen het opnieuw.

#SamenVooruit

01.10.2025 05:18 β€” πŸ‘ 347    πŸ” 113    πŸ’¬ 16    πŸ“Œ 14

On LLM's

06.10.2025 13:59 β€” πŸ‘ 0    πŸ” 0    πŸ’¬ 1    πŸ“Œ 0
Preview
ELLIS PhD Program: Call for Applications 2025 The ELLIS mission is to create a diverse European network that promotes research excellence and advances breakthroughs in AI, as well as a pan-European PhD program to educate the next generation of AI...

I'm looking for a doctoral student with Bayesian background to work on Bayesian workflow and cross-validation (see my publication list users.aalto.fi/~ave/publica... for my recent work) at Aalto University.

Apply through the ELLIS PhD program (dl October 31) ellis.eu/news/ellis-p...

06.10.2025 09:28 β€” πŸ‘ 38    πŸ” 30    πŸ’¬ 0    πŸ“Œ 1
Angry goose meme where in the first panel the goose says "β€œAdults and children alike were pulled from their Chicago apartments" then in the second panel the goose is chasing the person angrily saying "WHO PULLED THEM, CNN?".

Angry goose meme where in the first panel the goose says "β€œAdults and children alike were pulled from their Chicago apartments" then in the second panel the goose is chasing the person angrily saying "WHO PULLED THEM, CNN?".

Interesting use of the passive voice you've got there, CNN..

04.10.2025 19:34 β€” πŸ‘ 802    πŸ” 88    πŸ’¬ 8    πŸ“Œ 4
Preview
Onze rechtsstaat is niet op het gevaar van autocratie voorbereid, zegt deze hoogleraar rechtspleging Hoogleraar rechtspleging Jonathan Soeharno maakt zich grote zorgen over de rechtspraak in Nederland. Zo heeft de minister van Justitie en Veiligheid veel te veel macht bij benoemingen en neemt het ver...

De Nederlandse rechtspraak lijkt onafhankelijk, maar achter de schermen heeft de minister van Justitie opvallend veel macht. En dat is een gevaarlijke kwetsbaarheid in ons systeem, waarschuwt hoogleraar en advocaat Jonathan Soeharno in gesprek met FTM. www.ftm.nl/artikelen/on...

05.10.2025 06:33 β€” πŸ‘ 226    πŸ” 123    πŸ’¬ 11    πŸ“Œ 12

Well, this constrains my ideas substantially already

03.10.2025 20:50 β€” πŸ‘ 3    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

Does the topic matter?

03.10.2025 20:46 β€” πŸ‘ 3    πŸ” 0    πŸ’¬ 2    πŸ“Œ 0

If you've ever wanted to learn how to make beautiful websites with #QuartoPub and #rstats , check out this workshop I'm giving in a couple weeks! It'll be a blast (and we're covering Quarto's brand new _brand dot yaml system!)

03.10.2025 18:36 β€” πŸ‘ 85    πŸ” 28    πŸ’¬ 3    πŸ“Œ 1

ffs

03.10.2025 18:16 β€” πŸ‘ 1    πŸ” 1    πŸ’¬ 0    πŸ“Œ 0

This is perhaps the ultimate expression of the phenomenon feminist theorist Marilyn Frye described 50yrs ago: that many self-proclaimed heterosexual men neither like nor desire women.
This is why the bros invented RealDolls & now AI "actresses:" they want femininity, not human beings who are women.

02.10.2025 21:19 β€” πŸ‘ 80    πŸ” 20    πŸ’¬ 1    πŸ“Œ 2

Die stortvloed aan moties zijn symptomatisch voor de stand van het politieke bestel: partijen staan in permanente campagnestand, korte termijn prevaleert boven alles en langdurige problemen oplossen is vooral een kostenpost die niet scoort.

03.10.2025 08:32 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

Surreal moment for America. Needless to say, if the normal police ever pulled something like this β€” pulling every single person out of an apartment building and handcuffing them to run warrant checks β€” they would be sued into oblivion.

Yet ICE is going to get away with it entirely.

02.10.2025 12:01 β€” πŸ‘ 5583    πŸ” 2804    πŸ’¬ 220    πŸ“Œ 209

This is so clearly illegal that I'd expect a Democratic mayor to call on police forces to protect citizens against this. I find it shocking that dem politicians in general and mayors specifically barely stand for their citizens.

02.10.2025 13:11 β€” πŸ‘ 4    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

I also don't remember it being any different.

02.10.2025 07:51 β€” πŸ‘ 1    πŸ” 0    πŸ’¬ 0    πŸ“Œ 0

Like, my brother in christ, your entire business is propped up by absurd government subsidies and if those vanished, you would almost immediately be forced to sell to a large ag company and resort to sharecropping.

02.10.2025 04:22 β€” πŸ‘ 5    πŸ” 1    πŸ’¬ 1    πŸ“Œ 0

@thomvolker is following 20 prominent accounts