How to deal with variables that are only relevant for some people? I am reviewing an article. I can't be specific, but it involves validating a test for a health condition. Their goal is to come up with a score for risk of the condition. One variable is pregnancy.
Does this mean that they should validate the test separately for men and women? Or is it fine to include everyone and just mark "no" for pregnancy in all men?  
 A: My gut sense is to validate them separately because at the end the male's scores should probably be prorated to accommodate one fewer risk factor anyway, may as well just do that now if they have enough sample.
The real question is perhaps: are non-pregnant females and males share the same risk, all else equal? One method I think may be able to at least parse out that is fitting a sex-by-pregnancy interaction:
$$risk  = \beta_0 + \beta_1 female + \beta_2 preg + \beta_3 (female \times preg)$$
I'm omitting other independent variables here for the sake of simplicity.
Then, based on this model, for men: $$\hat{risk_{male}}  = \beta_0$$
For non-pregnant women: $$\hat{risk_{female, p-}}= \beta_0 + \beta_1 female$$
For pregnant women: $$\hat{risk_{female, p+}}= \beta_0 + \beta_1 female + \beta_2 preg + \beta_3 (female \times preg)$$
If $\beta_1$ is significantly different from 0 then we have evidence that non-pregnant women and men have different risk, and validation should be stratified by sex.
