This probably has a really straightforward answer, but I can't seem to wrap my brain around this, so I'm hoping someone can help me. It's clearly related to event history type data, but it's not exactly the same thing as what we normally see.
Imagine the following dataset, where "1" for startdate1 means you started a book in month 1, and a "1" for enddate3 means you ended a book in month 3. But the twist is that it's not easily separated into discrete books (and for various reasons too strange to mention here, it might not make sense anyway for the actual task at hand).
Is there an automated way to count the distance between the time someone starts reading a book and ends reading a book? So for the first observation, I would count the distance between startdate1 and enddate2, and then from startdate3 to enddate6 (listed in two different variables). But then for observation #2, I would only fill in the first variable (from startdate2 to enddate6).
Thanks for your time. I greatly appreciate it.
Imagine the following dataset, where "1" for startdate1 means you started a book in month 1, and a "1" for enddate3 means you ended a book in month 3. But the twist is that it's not easily separated into discrete books (and for various reasons too strange to mention here, it might not make sense anyway for the actual task at hand).
Code:
startdate1 startdate2 startdate3 startdate4 startdate5 startdate6 enddate1 enddate2 enddate3 enddate4 enddate5 enddate6 1 0 1 0 0 0 0 1 0 0 0 1 0 1 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 1 0 0 1 0 0 0 0 1 0 1 0
Thanks for your time. I greatly appreciate it.
Comment