Hi there,
I'm working with some panel data, whereby for each subject I have multiple events (lab tests) recorded in long form. Each event is dated and I need to calculate whether two specific tests (test_id 12 and 147) are conducted within 3 months of each other (to assess whether testing/diagnostic guidelines are being followed). Subjects may have multiple instances of each test.
At this moment in time, I'm considering looping through all instances of these tests to ascertain whether the other test occurs within 3 months. Given some subjects have 100s of test records and the dataset contains 100,000s of subjects, I'm wondering whether there is a more efficient method to derive my requirements.
(I found plenty of existing threads on the topic of dates and panel data, but nothing akin to the above)
Thanks in advance,
Rob.
Related Posts with Differences between dates using panel data
within-between-Interations in hybrid models for panel dataDear Statalists, I have a question concerning the possibility of using interaction terms in a hybri…
Weighting and Clustering in Pooled Data AnalysisI am working with DHS (Demographic and Health Survey) data. I have pooled data from about 25 countri…
Struggling with reshapeHi, I have data where i am looking at IDs, a test for different genes and extra information. I am tr…
Generating a Count Variable using the 90 percentile centered on a five day window Hi I am working with a panel data set for 300 districts from 1959 to 1999 using Stata 13. I have go…
Principal Component AnalysisI am working with data for Indian schools. I intend to create an Index by combining several variable…
Subscribe to:
Post Comments (Atom)
0 Response to Differences between dates using panel data
Post a Comment