Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
I am trying to capture patient visits to determine if they are compliant or not. There is a column [Visit Type], which includes Intial
Visit, Quarterly visit, Monthly visit, Annual Visit, Acute/follow up visit, Post Hospitaliztion visit. I would like to return a column with a value "compliant" or "not-compliant" for each patient. If a patient is not seen every month then they are considered not compliant, additionally if they don' have a quarterly visit every 3 months they are not compliant. Every 3 months there should be a Quarterly or possibly Annual visit and in between these there should be some combination of Monthly, Post Hospitalization, Acute/Follow up Visit. If the patient has an effective end date the result should be "discharged"
Any help would be greatly appreciated.
Expected output is a new table with the patient name and a new column (Evaluation) that returns a value of Discharged, Compliant, or Not Compliant. I have a sample visualization that I am working on but I cant get figure out the calculation to return the expected result
| Visit Type | Group Number | Effective Begin Date | Patient Name | Patient Birth Date | Patient Code | Note Date | Physician | Patient Departement | Effective End Date |
| Initial Visit | 10010000272S | 7/1/2021 | Bill Nelson | 2/22/1974 | INS CHG | 1/4/2022 | Bob Marshal | ABC Company | 4/30/2022 |
| Quarterly Visit | 10010000419S | 7/1/2021 | Paul Conner | 9/11/1948 | 3/5/2022 | Kim Blunt | 123 Company | ||
| Annual Visit | 10010000353S | 1/9/2022 | Bonnie Thorn | 7/3/1936 | 8/2/2022 | Henry Clark | ABC Company | ||
| Acute/Follow Up Visit | 10010438139S | 1/1/2022 | Mindy Jenkins | 8/20/1951 | 5/5/2022 | Henry Clark | ABC Compnay | 9/28/2022 | |
| Monthly Visit | 10010000419S | 2/15/2022 | Hope Walker | 7/9/1981 | INS CHG | 10/1/2022 | Mary Beth | 123 Company | |
| Post Hospitalization Visit | 10010028210S | 7/4/2022 | Cindy Stewart | 11/21/1952 | 6/4/2022 | Cheryl Holder | ABC Company | ||
| Quarterly Visit | 10010028210S | 7/4/2022 | Cindy Stewart | 11/21/1952 | 7/24/2022 | Cheryl Holder | ABC Company |
I think sample data is not enough.
if you have different scenarios, you need to provide the data for all scenarios.
hope i didn't misunderstand your question.
e.g
TOM 2022/1/1, 2022/2/1,2022/3/1
Jack 2022/1/1, 2022/4/1, 2022/7,1
Peter, 2022/1/1,2023/1/1
Linda 2022/1/1,2022/2/1,2022/6/1
we have monthly visit, quarterly visit, yearly visit and other scenario, the output for XXX is YYY
something like that
Proud to be a Super User!
could you pls provde the sample data(not the screenshot) and the expected output
Proud to be a Super User!
I added the expected output above and included a screenshot of what I was working on. Does this give you enough information to go on @ryan_mayu ?
what's the expected output based on the sample data you provided?
Proud to be a Super User!
I am hoping to have either a measure or a calculated column the returns "Compliant", Not-compliant", or "Discharged" regarding each patient visit row.
The criteria for compliance:
- Patients needs to be seen at least once a month (regardless of visit type). If there are any months were a patient doesn't have a visit they are Non-compliant.
- Patient need to record a Quarterly or Annual visit once every three months. If there are no quarterly or annual visits in a three month span they are also Not-compliant.
- If an empolyee has an Effective End Date entry they are designated Discharged
I hope this makes sense.
based on the sample data, two patients have end date, so the output is discharged. only cindy has two records and visit monthly, so we mark her as monthly visit, the rest leave blank, is that what you want?
Proud to be a Super User!
Hi Ryan, The discharge output is correct. The "monthly" output is not correct. Monthly is a visit type. The only 3 output categories would be Compliant, Not-compliant, or Discharged. If a patient had months were they were not seen then they would be not compliant. If a patient didn't have a a quarterly or annual visit every three months then they would be not-compliant. This might be better to do as a measure instead of calc column. Most patients have multiple rows for each of their visit types on the respective dates. I essentially want to evaluate all of there dates and visit types and determine compliant, not compliant or discharched.
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 39 | |
| 37 | |
| 33 | |
| 32 | |
| 29 |
| User | Count |
|---|---|
| 132 | |
| 88 | |
| 82 | |
| 68 | |
| 64 |