View Single Post
  #2   Report Post  
 
Posts: n/a
Default percentage formula

"Gina" wrote:
Example: 13, 45, 25, 12, 56, 32, 08. how many of these
are over 25 and what percentage of the total is that?


Bear in mind that there are many ways to solve a problem.
Here is one that might fit your needs, using your example.

Put the values 13,...,08 into cells B1:B7. (I am reserving
column A for descriptive titles.) In C1, put the formula
=IF(B125,B1,""), and copy C1 to C2:C7. (That creates
the formula =IF(B225,B2,"") etc.) In B8, put the formula
=SUM(B1:B7), and copy B8 to C8. (That creates the
formula =SUM(C1:C7).) In D8, put the formula =C8/B8,
and format the cell as Percentage with 2 decimal places
(or whatever you want).

That meets your basic needs, and it allows you to see
what is happening numerically, as check.

There is a more direct approach. After putting the values
into B1:B7, put the following formula into any cell of your:
=SUMIF(B1:B7,"25")/SUM(B1:B7), and format the cell as
Percentage.

(You might want to use absolute cell references like $B$1,
which you can get by pressing F4.)