Press "Enter" to skip to content

Day: July 23, 2026

Ways to Impute Missing Data in R

The DataScience+ desk compares methods:

Missing data is the daily reality of medical and epidemiological work: a patient skips a lab draw, a questionnaire item is left blank. So in this tutorial I use real health-survey data and compare three current imputation packages on it: mice (multiple imputation, still the reference method for statistical inference), missRanger (random-forest imputation, the fast successor of missForest), and VIM (k-nearest-neighbour imputation). Before any imputing I use naniar, the modern, ggplot-native toolkit for missing data, to picture where the gaps are. I also include the method most analyses actually use by default, dropping incomplete rows, because seeing why it fails is half the point.

I start from complete records, delete values myself, and check each package against the truth I hid.

Click through for the method and different ways to impute data to fill in the gaps. The text of the article looks AI-generated, though the recommendations end up being pretty solid (at least in my experience with imputation and working with mice).

Leave a Comment

Page Splits in Animated Form

Brent Ozar paints a picture:

You’ve heard that page splits are bad, and they’re an indication that your table design is making your storage work too hard. You’ve heard that the right answer to fix it is adjusting fill factor lower, or doing regular index maintenance.

Before you watch the below animation, you’ll wanna get up to speed with how index seeks work. Then, let’s explain page splits with an animation:

Click through for the visual explanation.

Leave a Comment

Working with DATEDIFF() and DATETRUNC()

Erik Darling has a video for us:

So we’re going to talk about just some not terribly advanced stuff, but stuff that is at least worth making sure that everyone understands when it comes to the date diff function.

There’s not terribly a lot of advanced things to say about it, but who knows where you’re starting off. So one thing that seems to get on some people’s nerves is deciding on a boundary.

So when you say, I only care about a year of data, you need to think carefully about how you do that. 

This is one tiny part of how working with dates is so painful, and not specifically due to any gap in tooling but just in how complex date and time logic is. And that’s before we even think about the date math involved in working with the Future Semiconditionally Modified Subinverted Plagal Past Subjunctive Intentional.

Leave a Comment

Exfiltrating Data via sp_invoke_external_rest_endpoint

Vlad Druma slides some data past the bouncer:

In this post I cover how an attacker can take advantage of SQL Server 2025’s sp_invoke_external_rest_endpoint to exfiltrate data from a compromised instance.

In my previous post I used sp_invoke_external_rest_endpoint to get some data about internet-exposed SQL Server instances.
While doing that, I realized that, similarly to xp_cmdshell, SQL Server 2025’s sp_invoke_external_rest_endpoint can be used by an attacker to exfiltrate data from SQL Server.

Click through to see how.

Leave a Comment