{
"$type": "site.standard.document",
"bskyPostRef": {
"cid": "bafyreig5xpxhiegfh6astysar64qvopbtzn6d3afvme5i7qqva7tlie4hm",
"uri": "at://did:plc:wwyqal4cnqhuwyacdj7rqq3n/app.bsky.feed.post/3mkbgh5kgj6m2"
},
"path": "/t/rms-modeling-longitudinal-responses/4791?page=4#post_67",
"publishedAt": "2026-04-24T16:43:06.000Z",
"site": "https://discourse.datamethods.org",
"textContent": "This question is regarding the choice of time variable—whether to model time at a finer resolution (days) or at a higher level (years)..\n\nI am analyzing data for a study where the goal is to analyze the duration of medication use before and after intervention, how the trend in medication use changed before and after intervention.\n\nthe data structure is as follows\n\n`ID ChildDOB Duration (medication use)`\n`101 2018-04-21 2`\n`105 2018-05-10 4`\n`206 2019-07-02 1`\n`107 2019-06-17 10`\n`201 2019-06-17 9`\n`.`\n`.`\n`.`\n`.`\n`103 2021-02-15 5`\n`210 2021-08-17 3`\n`203 2021-09-30 2`\n`215 2021-10-07 1`\n\nWhat I am proposing is to use time as days before and after intervention\n\n`ID ChildDOB Duration (medication use) time(days before/after intervention)`\n`101 2018-04-21 2 -680`\n`105 2018-05-10 4 -661`\n`206 2019-07-02 1 -243`\n`107 2019-06-17 10 -258`\n`201 2019-06-17 9 -258`\n`.`\n`.`\n`.`\n`.`\n`103 2021-02-15 5 351`\n`210 2021-08-17 3 534`\n`203 2021-09-30 2 578`\n`215 2021-10-07 1 585`\n\nThere is a suggestion that we use time in years from intervention instead of days\n\n\n ID ChildDOB Duration (medication use) time(year before/after intervention)\n 101 2018-04-21 2 -2\n 105 2018-05-10 4 -2\n 206 2019-07-02 1 -1\n 107 2019-06-17 10 -1\n 201 2019-06-17 9 -1\n .\n .\n .\n .\n 103 2021-02-15 5 1\n 210 2021-08-17 3 2\n 203 2021-09-30 2 2\n 215 2021-10-07 1 2\n\n\n\nI am not in favor of using time as years (1 or 2) before or after intervention. I prefer using\ntime in days(-680, -661, -258, 534 etc…\n\nI am confident that using time in days is the right approach, I like some help understanding\na) why time(days) is better than time(years) also\nb) if using time(days) would change the interpretation in anyway ?\n\nThanks.",
"title": "RMS Modeling Longitudinal Responses"
}