Friday, March 25, 2016

Analyze Data to Identify type of Readmissions using PostgreSQL

Analyze Data to Identify Causes of Readmissions using PostgreSQL

What is patient readmission

Normally Readmission is - if a patient returns within 30 days of previous discharge.

reason for readmission

Multiple factors contribute to avoidable hospital readmission: they may result from poor quality care or from poor transitions between different providers and care settings.

The problem of readmission to the hospital is receiving increased attention as a potential way to address problems in quality of care, cost of care, and care transition

readmission table structure

After cleansed and identified the required attribute to get the readmission details, my entity model look like this

patient_id disease adm_date dis_date
1069 Oncology 6/17/2013 6:51 6/21/2013 7:15
1078 Neuro 7/18/2013 12:10 7/20/2013 08:12
1082 Ortho 7/19/2013 12:10 7/22/2013 08:12
1085 Cardiothor 8/25/2013 12:10 8/27/2013 08:12
1085 Cardiothor 9/13/2013 12:10 9/16/2013 08:12

Now, we have to write a query to get the list of readmission details. Condition is, current admit date is between the last discharge date and 30 days from then.

readmission query in postgresql

Select count(*) "Readmission Count", disease
From readmission_view v
Where Exists
Select * From readmission_view
Where patient_id = v.patient_id and
v.adm_date between dis_date and dis_date + 30
group by disease
order by count(*)

readmission result

disease Readmission Count
Ortho 878
Neuro 567
Oncology 155
Using the result optioned from the query to find the percentage of patient readmission. based on the result need extra care on the disease.

No comments: