I am trying to create a formula in Numbers which takes a duration and calculates what percentage this is of another duration.
For example, I have a duration of 1h 30m
in cell A1. I want to calculate what this is as a percentage of 9h. I am trying to output 17%.
I tried diving the cell A1 by 9, but this (rightfully) outputs a duration as A1 is being divided by a number. I need to divide A1 by another duration (i.e. 9h) in order to get a fraction. Is it possible to do this directly in the formula? The only other way I can how to do it is by inputing a duration of 9h
into cell B2, and then writing =A1/B2
. However, I would prefer being able to avoid using the auxiliary cell B2 when performing this calculation.
Best Answer
Divide by text in quotes.
So if you want to divide
A1
which contain"1h 30m"
by"9m"
then use the following functionA1 ÷ "9m"
(A1
contains"1h 30m"
). This is the equivalent of putting"9m"
inB1
and then in using the function"A1 ÷ B1"
inC3
: Both will give you10
because 9 minutes goes into 1 hour 3 min 10 times.