# Is logistic regression still valid where there are repeated measurements and generalized estimating equations is the real deal?

I have a model with a binary dependent variable (DV) and 5 independent variables, all of which are matched (each person, twice).

I think since these matched INDEPENDENT variables can be considered "repeated-measures", generalized estimating equations (GEE) is the best approach here. However, I have used binary logistic regression.

Do you think this analysis is valid? Or is it just of lower power or less elegant than GEE?

I can handle a lower power or less elegance, but not invalid. By "invalid" I mean where some assumptions are not met and the test is incorrect.

My guess is that since binary logit discards the correlations between the repeated measures, it is a special case of repeated measures with zero correlation. So it might still be valid, but less useful than GEE.

Am I right?

Besides, I doubt if matching the independent variables is considered repeated measures. I am confused.

• Don't let the wording trick you. You matched individuals by some independent variables (such as age, gender and whatnot), but your outcomes are likely to be dependent within matched pairs of individuals. Conditional (fixed-effects) logistic regression is a possible simple way to go here. Commented Aug 20, 2013 at 12:00
• Wow you mean it is not repeated-measures? phewww such a relief! Many thanks. I would replace my simple logit with conditional one. THANK YOU! :)
– Vic
Commented Aug 20, 2013 at 12:19
• On a side question, is the usual logistic regression (unconditional) I used is still valid?
– Vic
Commented Aug 20, 2013 at 12:20
• If your data is clustered or repeated measures than regular logistic regression may not be appropriate. A mixed effects model or GEE should be used if autocorrelation is strong.
– Jon
Commented Feb 17, 2017 at 22:09

I agree with @andrea that it is common to see "matched individuals by some independent variables", but not "matched independent variables".

If individuals are matched, it is repeated measures. Zero correlation can happen but is rare, so the usual logistic regression you used may not be valid. The conditional logistic regression or GEE is robust to handle the correlation within repeated measures.

The difference between conditional logistic regression and GEE is the interpretation, where the former getting the subject specific estimate and the latter the population average estimate.

• Hey Randel are you still there? Do you know why SPSS GEE doesn't run when duplicate cases exist? If it is going to be repeated-measures, it has to expect duplicated cases. But it keeps giving me this error: "There are at least two records with the same values for the subject and within-subject variables. No output will be displayed. Execution of this command stops." From studying other forums and Googling, I know this is caused by duplicated cases in the sample, but wasn't it supposed to be "repeated-measures"?! So why it cannot tolerate duplicate cases? Do you have any idea?
– Vic
Commented Aug 24, 2013 at 16:49
• I think the SPSS help file is a good reference. Is your data format as the first table? As in the second table of the example, you should set center and id as subject variables and year as within-subject variable. Commented Aug 25, 2013 at 2:28
• Many thanks dear Randel. I did it but I had to create a dummy variable (since I did not have such a center variable). So my cases became unique and SPSS did run the test. However I am not sure if the result is any valid, since my subject is now "Dymmy * PatientID" instead of PatientID alone. So how would SPSS recognize which real clusters to use... I would think on it more and look at SPSS example (thanks), but see R does not care about case duplications and smoothly runs, and also much faster. :)
– Vic
Commented Aug 25, 2013 at 8:57
• It is hard to imagine without taking a look at the data table. Is the data as you posted here? If so, you should set PatientID as subject variable and TREATMENT as within-subject variable. What does Dymmy denote then? Commented Aug 25, 2013 at 16:17
• Yes that address. Oh not dymmy, "dummy". Sorry. In SPSS, there was NO way to work around it. It kept returning a stupid error which indicates that two cases have the same values (duplicated). So the IBM website suggested to add a second identifier for the patients, apart from PatientID. But I don't have a real second identifier, so I have to make a Dummy identifier. But that would render my results incorrect I think.
– Vic
Commented Aug 25, 2013 at 16:28