Forum Discussion

PFGraham's avatar
PFGraham
Copper Contributor
Jun 01, 2023
Solved

CountIF or SumIf or SubtotalIf - array question

Hello Excel Geniuses,

 

I'm working on an insane spreadsheet that I 'got hold' of, trying to do some extractions on desperate sets within it.

 

Anyway, the problem today is related to this set: 3 columns: ID, Spend, variable . Looks like this:

IDSpendvariable 
1$4,500x
2$0 
3$9,000x
4$5,000x
5$16,000x
6$0 
7$6,000x
8$0x
9$21,632 
10$0x
11$0 
12$14,300 
13$6,000x
14$15,000x
15$3,000x
16$19,805 
17$9,000x
18$16,000 
19$3,750x
20$0x
21$7,500x
22$12,678 
23$27,000 

 

I trying to find the Average of Spend IF Variable="x" AND not to include any Spends in the Average calculation if $0.

 

So, only give me the Average if it's a X in the Variable column but don't drag down the Average calculation with any $zero spends.

 

 Thanks!

Resources