I have two periods of panel data and I am trying to see if coefficients change over time. I would like to control for individual-level heterogeneity, but not sure how to do it with a complex design object and svyglm function:
```r
# Libraries
library(survey)

# complex survey design
des <- svydesign(
  ~ secu , # stratum half-sample code
  strata = ~stratum , # std error stratum
  weights = ~wtresp , # weights
  nest = TRUE ,
  data = long
)
```
In the regression below the outcome variable is the retirement status. The regressors are dummy variables for sex, education, race, self-reported health, age, income. In order to see if the effect of these variables becomes stronger in the second period, I include a time dummy variable which equals to 1 if the respondent's interview is from the 2nd time period, (and 0 if from the 1st). I also include dummy variables for month and year when the interview was collected.

```
summary(svyglm(
  retired ~ time*(female + college + factor(race) + age + Rshlt + 
            log(iearn + 1) + factor(month) + factor(year)),
  design = des
))

```
I have tried using `plm()` with weights, but not sure if it is an appropriate method for complex survey samples.