# How to calculate a linear combination of regression coefficients after multiple imputation?

A method to handle missing data is with multivariate imputation by chained equations. During this process, we create many datasets (as many as you specify) with imputed values for the missing data. Then, models are fitted for each of the datasets and the estimated coefficients across all the fitted models are pooled to give the "final" pooled estimated coefficients.

I am not interested in interpreting these estimated coefficients. I would like to calculate a linear combination of the estimated coefficients from my model. My question is how should I do this calculation.

I see two major options on how to do this:

1. Treat the estimated pooled coefficients as what I need, and calculate the linear combination from them.
2. Calculate the desired linear combination for each imputed dataset and model, and then pool all the calculated linear combinations.

Are either of these options the correct method for calculating a linear combination of regression coefficients after performing multiple imputation by chained equations?

As an illustrative example:

I have used the mice package in R to impute a dataset and used the subsequent with() and pool() functions to produce a pooled estimate of regression coefficients. But I am not interested in the coefficients alone. I would like to calculate a linear combination of the estimated coefficients.

Context: logistic regression with three predictor variables

library(mice)
set.seed(123)

# Create the outcome variable
Y <- sample(c(0, 1), 100, replace = TRUE)

# Create the predictor variables
missing_prob <- 0.05
Animal <- ifelse(runif(100) < missing_prob, NA, sample(c("Cat", "Dog"), 100, replace = TRUE))
Size <- ifelse(runif(100) < missing_prob, NA, sample(c("Small", "Large"), 100, replace = TRUE))
X <- ifelse(runif(100) < missing_prob, NA, rnorm(100))

# Combine the variables into a data frame
data <- data.frame(Y, Animal, Size, X)

# Use MICE
imp <- mice(data)
fit <- with(imp, glm(Y ~ Animal*Size + X, family="binomial"))
pooled.fit <- pool(fit)
summary(pooled.fit)


So, can I use the output from summary(pooled.fit) to calculate my linear combination of, say, log-odds of Y=1 given Animal=Cat, Size=Large, and X=3? Or, should I calculate the desired linear combination for each imputed dataset found within the imp object and then pool all linear combinations?

A similar question was posed here and was closed.

• Any linear combination of regression coefficients is mathematically identical to a regression coefficient (just change the basis of explanatory variables). Is there something special about your analysis that would suggest otherwise?
– whuber
Commented Jun 26, 2023 at 14:12
• After considering your first sentence, both option 1 and option 2 that I suggest would produce an identical calculation? @whuber
– Reid
Commented Jun 26, 2023 at 14:46
• I hesitate to concur because (1) both calculations are random and independent (thus, even the same calculation shouldn't give the same result when re-run) and (2) I don't see any linear combinations here. The only possible linear combinations of "log-odds of Y=1..." are multiples of that (single) log odds estimate.
– whuber
Commented Jun 26, 2023 at 15:49