Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unexpected result for analysis 110: not covering all months with observation period #751

Open
MaximMoinat opened this issue Mar 8, 2024 · 0 comments

Comments

@MaximMoinat
Copy link
Contributor

Expected behavior

Given this mock observation period data, I expect analysis 110 gives a row for every month from 202201 to 202401. There is continuous observation for at least one person between those dates.
image

Observed behavior

Only three months are included in the result.
image

Investigation

It seems like only months in which an observation period is started are included in the result. While this might be expected for most data, this does create edge-cases where this is not handled correctly (e.g. if observation periods only start in first of the month, or the last month not being included as described in issue #20)

For replication, this is the mock data used:

INSERT INTO observation_period (observation_period_id, person_id, observation_period_start_date, observation_period_end_date)
              VALUES 
                (1, 1, '2022-01-01', '2023-01-01'),
                (2, 2, '2023-01-01', '2024-01-01'),
                (3, 3, '2023-06-01', '2024-01-01')
;
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant