Forum Discussion

ConcreteKid's avatar
ConcreteKid
Copper Contributor
May 09, 2024

Only including cells containing certain words / numbers in formula?

I have a new job as a sepsis specialist nurse.  At the end of the month, using all the data inputted throughout the month, I have to work out how many high risk patients received IV antibiotics within 1 hours.  I would greatly appreciate your help, as I have never worked with Excel before

 

So the calculation I'm after would be as follows:

 

Only include only patients categorized as HIGH (column I) which contains either High or Low.  Of these I need to take any patient with 01:00 (1 hour) or less (Column Q).  Then divide by the total amount of High risk patients to give me a percentage of patients that received IV antibiotics within 1 hour.  Hope that makes sense

 

Thanks for your help

 

 

6 Replies

    • ConcreteKid's avatar
      ConcreteKid
      Copper Contributor
      Thank you. This is very much appreciated.
  • ConcreteKid 

    Create this formula:

     

    =COUNTIFS(I2:I1000, "HIGH", Q2:Q1000, "<="&TIME(1, 0, 0))/COUNTIFS(I2:I1000, "HIGH")

     

    If your data extend below row 1000, adjust the ranges accordingly.

    Format the cell with the formula as a percentage.

    • ConcreteKid's avatar
      ConcreteKid
      Copper Contributor
      If I needed to work out the percentage under 90 minutes, what would I change in the formula?
    • ConcreteKid's avatar
      ConcreteKid
      Copper Contributor
      This is great, thank you, works perfectly!