Hello,
I am building a regression model for ethnicity as a categorical exposure variable and death as an outcome. I want to assess the derived odds ratios across different socioeconomic statuses (modifier of effect). For socioeconomic status (SES) coded categorically from 1 to 10, there are missing data for which I am using MICE to handle. However, 10 categories are a lot and I need to group them into three broad categories, so the resultant variable (SES_cat) is a passive variable that depends on the imputation of SES.
I have tried the below syntaxes but I get a message stating

estimation sample varies between m=1 and m=2; click here for details
These are the syntaxes I attempted:

mi set mlong
mi register imputed SES
mi register regular death selfharm gender age
mi impute chained (mlogit, augment) SES = death i.selfharm i.gender age , add(10)

mi passive: gen SES_cat=0

replace SES_cat=1 if SES >0 & SES <5
replace SES_cat=2 if SES >4 & SES <8
replace SES_cat=3 if SES >7 & SES <11
mi update
mi estimate, or: clogit death i.ethnicity if SES_cat==1, group(matchedid)
I am also meant to check the odds ratios when SES_cat == 2 and SES_cat==3, but the error message I am getting so far tends to be explained by

here is something about the specified model that causes the estimation sample to be different between imputations. Here are several situations when this can happen:

1. You are fitting a model on a subsample that changes from one imputation to another. For example, you specified the if expression containing imputed variables.
What is the way around that? what can I do?

Your help is much appreciated.