# Systematically Missing Data

I have a problem regarding regression with sistematically missing data. I cannot describe the exact setting, so I will make up a situation that captures everything that is essential.

Let's imagine the following experiment setting: I am doing research on the probability of individuals participating in the labour market (binary variable). One of the independent variables in my dataset is the age of the first kid. When the individual has a kid, then the variable is simply its age. When the individual doesn't have offspring, it is NA. Note that the data is not missing at random: it reflects the observable characteristic that some people have kids while other don't. More importantly, it divides the sample into two sub-samples, in a way that is potentially very correlated with the outcome variable.

Now, how can I use this variable in a Logit model? I cannot simply fill the column with zeroes. I also cannot use the variable has_children x age_of_firstborn, since the value of that variable would be the same as just filling with zeroes. I also thought about doing two regressions, one for people with kids, and one for those who don't, but I think it would be a pity, because I would loose generality. I am not even sure if it can be considered truncated data. Any ideas?

There are a lot techniques for dealing with missing values (multiple imputation, EM, weighting, etc.) However, none of these apply to your situation, as your missing values are not missing values as these techniques understand them. For a value to be missing it first needs to exist. In your case the age of the child just does not exist for people without children, so it cannot be missing. Unfortunately for you, they still have a missing value code in your data. So you need to do something, but those techniques are not applicable to your situation.

Lets say you want to explain a variable $$y$$ with respondent's education ($$educ$$), which is observed for everybody, and age of youngest child ($$chage$$), which is only observed for people with children. The child's age cannot influence $$y$$ for persons without children; this characteristic just does not exist for those persons. So for these persons the logistic regression model is $$P(y=1|x)=\Lambda(\beta_0 + \beta_1educ)$$, where $$\Lambda(\cdot)= \frac{\exp(\cdot)}{1+\exp(\cdot)}$$. For people with children, your model is $$P(y=1|x)=\Lambda(\beta_0^* + \beta_1educ + \beta_2chage)$$. It reasonable to suspect that just the fact of having children has its own effect on top the children's age, so $$\beta_0\neq\beta_0^*$$.

You can estimate this model. The first step is to create a new variable indicating whether or not a person has children (in all likelihood you don't need to create that variable as it is probably already in your data). Lets call that variable $$child$$. The second step is to change the variable $$chage$$ to 0 for all persons without children. Than you can add $$child$$, and $$chage$$ to your model. So we have $$P(y=1|x)=\Lambda(\beta_0 + \beta_1educ + \beta_2chage + \beta_3 child )$$

If someone does not have children, then $$child$$ = 0 and $$chage$$ = 0. So the model becomes: $$P(y=1|x)=\Lambda(\beta_0 + \beta_1educ + \beta_2 0 + \beta_3 0 ) = Lambda(\beta_0 + \beta_1educ )$$, which is what we wanted.

If someone has children, then $$child$$ = 1. So the model becomes $$P(y=1|x)=\Lambda(\beta_0 + \beta_1educ + \beta_2chage + \beta_3 1 ) = \Lambda(\underbrace{\beta_0 + \beta_3}_{\beta_0^*} + \beta_1educ + \beta_2chage )$$

, which is what we wanted.

Notice that the number of variables in your model differ depending on whether $$chage$$ had a missing value or not. In your case that is exactly what we wanted, because quite sensibly we don't want to control for characteristics that don't exist for an individual. However this also means that this trick does not work for a general case of missing values, i.e. the value exists but we have not observed it.

• Thank you for the great answer. I guess you could furthermore add an interaction term multiplying educ and child to account for different effects of education on y depending on child?
– Job
Commented May 12, 2023 at 6:23
• Sure, you can add all kinds of interaction effects, but keep in mind that the purpose of a model is to simplify reality. Your model does not simplify much if you add all interactions... So there is always a trade-off. Commented May 12, 2023 at 7:26

What about binning the children's ages so that you have

$$Y=B_0+B_1(no\_child) + B_2(child0-2)+B_3(child2-4)...etc$$

I realize it's a logit but my latex skills are weak and the idea is the same even if this is the wrong syntax.

• The nice thing about this solution is that it acknowledges that children's age is likely to have a highly non-linear effect. For some dependent variables it is likely highly discrete (pre-kindergarten, kindergarten, school), like your solution suggests. For other dependent variables you might want to choose a more smooth function. It takes care of the systematic missing values in the same way as my solution: you set the dummy variables $child0-2$, $child2-4$, ... to 0 when child's age is missing, and add a dummy for no child. Commented May 15, 2023 at 7:19