Life or Death: Trip to the Hospital


Life or Death: Analyzing Hospital Data with SQL

Have you ever heard the term life or death situation? I'll tell you a story about a 4-year-old little girl. She was sitting in bed cuddled up with all her stuffed animals at home. She has an ear infection and a fever that’s being monitored and controlled. While watching cartoons, she asked her mom to read a story. Her mom is working remote at the desk next to the bed and taking care of her. "Yes baby, right after I finish sending these reports."

The little girl, even though sick, was happy and taking pictures with her camera of her feet and stuffed animals. Suddenly the camera shutter stops. Her fever rose and she became unresponsive. You run over to check on her. Her eyes are open and not responding when you repeatedly call her name. You know it’s time to go to the hospital ASAP!! Frantically, you do what any parent would do. Grab your baby, get the keys, get in the car, and go to the ER as quickly as possible.

It’s times like this you want the hospital to focus on your baby and the current emergency of her not responding. You hope she would take priority over others, that the doctors working on her are well rested and qualified, that the procedures and time at the hospital would ensure she is responsive again, and healthy to go home. You pray and hope she gets the treatment she needs despite her demographics and that she is taken care of with the best care.

Why This Project?

This is why I decided to do this project. The little girl in the story is my daughter and as a mom you want your kids, your family, your loved ones, to be in good hands in an emergency life-or-death situation. Ironically, I was working with several Hospital HRs responsible for doing background checks for 6 years at the time this incident happened. Work never stopped in client account management. It was a very demanding career choice. Both hospitals and university clients constantly emailing, calling, and needing their background reports as soon as possible to move forward with making important decisions such as who they plan to hire for emergency situations just like this. I believe this would be valuable knowledge to others, especially those curious about the healthcare industry, and interesting things I found in this data.


What Readers Will Gain

By reading this article, you will learn about:

  • My domain knowledge with HR Healthcare.
  • Key findings about the demographics of this specific hospital.

  • More women overall are going to the hospital than men across the board.
  • Most people are going to the hospital are in the 70s-80s range.
  • Most people are being discharged after 3 days. Only a handful of people are readmitted.
  • It may appear that certain minority groups are getting less labs done, but there is a reason why.


Dataset Details

The dataset used was from a Kaggle dataset located here. It has 101,767 rows and 50 columns sharing 101,766 unique customer information such as demographics, diagnosis, time in the hospital, and several other helpful columns to help me locate some interesting trends. I used MySQL to JOIN another dataset.

Analysis Process

Time in the Hospital

Naturally, I would imagine most people don't like to go to the hospital, and probably prefer to get out as quickly as possible. So I started to think, how long do people stay in the hospital overall? What's the distribution of time spent in the hospital look like?

bucket for days and count for total patients

In the hospital's case, the majority stay at the most 3 days and starts to go down as days go by. Which is good in this case, as this leaves more room for new patients to come in for treatment, and be able to leave once patients are heathy enough to be released, or are they?

Procedures

When I did background checks for hospitals one of the most important checks we did on each employee was to ensure no one had sanctions. Sanctions covered quite a bit such as criminal or unethical conduct, billing abuse, patient abuse or neglect, default on student loans, losing their healthcare license, misdemeanor regarding controlled substances, or overprescribing drugs. So this had me wondering about doctors and medical procedures being done. What are the medical specialties are on average and how many customers?


It was strange that some procedures were only limited to 1 customer. The list was also very long so I narrowed it down to 5 specialties to focus on. I decided to choose 50 or more customers to focus on.

Is Race a Factor in Healthcare?

You try to give people the benefit of the doubt and hope that you're being treated equally, especially in an emergency situation. Had we gone to a different hospital in a not-so-friendly environment, I would not know if my daughter would make it out alive because of our race.

So the first thing I was interested in was the average number of lab procedures broken down by race. Would my daughter or other minorities be treated differently than others? Possibly, my daughter looks more Asian, but she's actually 2 or more races, and though she looks more Asian according to these results more labs are done on other races? Why is that?



Looks Can Be Deceiving

Looking at this, I realized the reason has nothing to do with race at all. It actually has to do with how many minorities are visiting this specific hospital. Now if the hospital is located in an area that is predominantly minorities, we could get more accurate data if race is a factor.


Are We Done Yet?

Thankfully, in my case, my daughter became responsive within the hour and we were able to go home that same day. When she woke up she asked "mommy can you read me the story now?" It was music to my ears. I was one of the lucky ones. I wanted to see if others had the same success as I did with my daughter and was able to be released sooner than later.


CTE Assign a Variable
Success stories, discharged sooner

Finally, the last thing I was curious about was if anyone had any prescriptions and lab procedures. It would be nice to see it in written format. When I saw this, I thought wow, that's a lot of medications and procedures done, is that all in one day? I could understand if it was 3 times a day for 2 weeks, but it can't be on the same day or that would create a new emergency.



Conclusion and Personal Reflections

I'm a very visual person. Since SQL is very limited in the visual aspect, I exported the data from MySQL to an Excel file after I joined the tables, and imported the data to Tableau to uncover more insights. I also used Excel's Analyze Data tool to find other insights I might have missed from Tableau. As soon as I did this, I was able to find more insights immediately.

Main Takeaways

  • Sometimes looks can be deceiving. It's important to look at the overall view before making assumptions.
  • I wondered where this hospital was located to see if geographic location was a factor as to why less minorities visited.
  • The majority of those visiting the hospital are in their 70-80s, and tied in second were those in their 50-60s and 60s-70s
  • Those in their 20s and 30s visited the Emergency Room more along with Outpatient Services.

Call to Action

I am grateful that I completed this project. Sometimes in life you get caught up in your work and you forget what we are really here for, our family. It's important that data like this is being evaluated on a regular basis to ensure treatment is equal. People are treated like actual people and not just a number. I would love to hear your thoughts! Connect with me on LinkedIn, or if you or someone you know is looking to hire a data analyst, let’s talk! Feel free to leave a comment with your thoughts or questions.


Bright S.

Versatile Analyst | Seeking New Opportunities | Energy Business| Strong Background in Economics and Finance |Transforming Raw Data into Business Insights | Financial Modelling using Advanced Excel | SQL | GAMS | PowerBI

2 个月

I must say your projects are very insightful. Keep it up ??

Carmen Chow

Data Analyst | Excel | SQL | Tableau | Python | Google Data Analytics Professional Certificate | Delivering Data-Driven Solutions

2 个月

Really enjoyed your thoughts in this analysis, Jen! Your personal connection and experiences make your insights even more compelling. Well done!

Peg Blaine, RHIT, CPT

Data Analytics | SQL | Excel | Python | R | Tableau | Storytelling | HIM

2 个月

Great analysis and storytelling along with easy to follow SQL Jen Hawkins ?? Great job ??????

Omhari Gurung

Data Analyst | SQL | Tableau | Excel | Data Visualization

2 个月

Hi Jen, I can deeply relate to how you felt when your daughter collapsed due to an ear infection. My mom experienced a similar situation with an ear infection, so I understand how concerning it can be. Currently, her cataract operation, which was scheduled for today, has been postponed to February because her doctor is on leave. Wishing your daughter a speedy recovery and hoping everything works out smoothly for you and your family! Great analysis as always. Loved step by step analysis . And the finish up is solid. Have a great day ahead ?? ??

要查看或添加评论,请登录

Jen Hawkins的更多文章

  • Confessions of an Accidental Delivery Driver: Tableau Supply Chain Project

    Confessions of an Accidental Delivery Driver: Tableau Supply Chain Project

    I never imagined I'd find myself delivering food, medicine, packages, toilets, penguins, or toilet paper..

    29 条评论
  • Why The Great Resignation

    Why The Great Resignation

    The Great Resignation: People Analytics R Project Imagine your boss just grilled you on the numbers that day and more…

    13 条评论
  • Data Mining for Iron Ore

    Data Mining for Iron Ore

    Data Mining Iron: Python Project I never imagined I would be talking about iron and mining iron data in a project…

    10 条评论
  • Are Your Customers in a Situationship?

    Are Your Customers in a Situationship?

    Discover Loyalty Patterns with DoorDash! The project focuses on analyzing loyal customer behavior for DoorDash. I was…

    2 条评论
  • Sneak Peek World Bank: SQL Project

    Sneak Peek World Bank: SQL Project

    What's it Like to Work in Banking and Finance? Have you ever wondered what it’s like to work at a bank? How are banking…

    29 条评论
  • Dropout to Death Row: Tableau Project

    Dropout to Death Row: Tableau Project

    High School or Jail? That's an easy one, I'd rather go to school. So you're saying just because I decided to drop out…

    8 条评论
  • DoorDash: Elevate from Situationship to Commitment

    DoorDash: Elevate from Situationship to Commitment

    ***Disclosure: this is not your average project. I’ll be sharing some funny commentary, but please don’t take offense.

    36 条评论

社区洞察

其他会员也浏览了