I have a question in mixed models. I'm quite new at this field and I'm trying to calculate a model in which "y" is predicted according to multiple covariates (Age,gender,BMI) and the random variable "randX". randX has two different unique values and I have 150 repeats with each of the values. I want the var-cov matrix to be a diagonal matrix with the same variance for both of randX types (but zero variance between the types). I read a lot about this subject and this is what I did so far. I have no idea if this is the right model.
model <- lme(y ~ Age+gender+BMI, data = df, random=list(randX = pdIdent(~Age+gender+BMI)), method = "REML")
please help me with that. Thanks.