4
$\begingroup$

I collected data at four waves (i.e., four time points), and I want to use a linear mixed model to analyze the data. Is it better to treat the time variable as categorical or continuous?

$\endgroup$

2 Answers 2

4
$\begingroup$

It is unlikely that a random effects model will adequately fit the serial correlation pattern you are likely to see in such data. See this for more.

Are the four time points exactly the times at which measurements were made, or are they target measurement times? If the latter it is best to use the actual measurement times in a continuous-time model (continuous both for the mean Y and for the correlation structure).

If time is indeed discrete (the first case listed above), you can treat it as discrete, which requires 3 degrees of freedom, or as quadratic or a restricted cubic spline with 3 knots, each requiring 2 d.f.

$\endgroup$
2
  • $\begingroup$ Thank you! I collected data in May 2019, February 2020, October 2020, and June 2021, and I want to compare whether the dependent variable varied across different waves. Is it better to treat the time variable as categorical or continuous? $\endgroup$
    – Misaya
    Feb 20 at 14:12
  • $\begingroup$ The data is from the same large group. $\endgroup$
    – Misaya
    Feb 20 at 14:18
1
$\begingroup$

It is up to you to chose according to how the different time points relate to each other in your experiment. My intuition is that it should not change anything to the overall result. I would try both and compare.

Edit after your comment : I would treat it as categorical. Many things can have changed from one year to an other, the data was not even collected in the same season.

$\endgroup$
1
  • $\begingroup$ Thank you! I collected data in May 2019, February 2020, October 2020, and June 2021, and I want to compare whether the dependent variable varied across different waves. Is it better to treat the time variable as categorical or continuous? $\endgroup$
    – Misaya
    Feb 20 at 14:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.