{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreifmhmnpgppk22flp34k6am55mqjtrg524eulqrty5sxz53mwgzvg4",
"uri": "at://did:plc:wwyqal4cnqhuwyacdj7rqq3n/app.bsky.feed.post/3mj3rdtvvc7z2"
},
"path": "/t/power-calculations-in-longitudinal-mixed-effects-from-two-measurements-to-three-measurements/28699#post_1",
"publishedAt": "2026-04-09T13:35:45.000Z",
"site": "https://discourse.datamethods.org",
"tags": [
"WebPower - Statistical Power Analysis and Sample Size Planning for Linear mixed-effects model",
"Rplot02.pdf",
"power_simulation_results_wide.pdf",
"Report6 gee.pdf"
],
"textContent": "Hi everyone. In recent weeks, I’ve been going down the rabbit hole about power calculations for longitudinal mixed effects.\n\nOne: in PAS software, it states that both in the GEE and mixed effects options, the power remains the same as we move from two measurements to three measurements\n\nSecond: The same results are yielded by the software WebPower - Statistical Power Analysis and Sample Size Planning for Linear mixed-effects model\n\nThree: it appears that many of these calculations are based on the book Sample Size Calculations for Clustered and Longitudinal Outcomes in Clinical Research. Sponsored by LLMs, I was able to reproduce their table 5.3\n\n.\n\nThen I extended the codes to two, three, and four measurements. In that simulation, actually, the power increased a little bit, but almost no impact.\n\n**So questions are:**\n\n 1. Are this references and code correct? I find it extremely counterintuitive and surprising that adding a third measurement has no/almost no impact on power.\n\n\n\n\n\nI was expecting a 10 to 20% decrease on the sample size depending on the circumstances\n\n 2. On that note, does anyone have a verified R script that correctly calculates power for longitudinal designs in these scenarios?\n\n\n\n\n\nI have attached some reports. Thank you\n\nRplot02.pdf (34.6 KB)\n\npower_simulation_results_wide.pdf (236.3 KB)\n\nReport6 gee.pdf (313.7 KB)",
"title": "Power Calculations in Longitudinal Mixed Effects - from two measurements to three measurements"
}