I have negative and positive numbers (hours) that I want to sum from several categories on my spread sheet. Each category has a subtotal.
I want to sum both positive and negative hours in one column (start to finish) without including the subtotals. Any help would be much appreciated. Thank-you.
[TABLE="width: 400"]
<colgroup><col><col></colgroup><tbody>[TR]
[TD][TABLE="width: 1146"]
<colgroup><col><col></colgroup><tbody>[TR]
[TD][TABLE="width: 180"]
<colgroup><col></colgroup><tbody>[TR]
[TD] 1[/TD]
[/TR]
[TR]
[TD] -1[/TD]
[/TR]
[TR]
[TD] 2[/TD]
[/TR]
[TR]
[TD] -2[/TD]
[/TR]
[TR]
[TD] 3[/TD]
[/TR]
[TR]
[TD] -3[/TD]
[/TR]
[TR]
[TD] 4[/TD]
[/TR]
[TR]
[TD] -4[/TD]
[/TR]
[TR]
[TD] 5[/TD]
[/TR]
[TR]
[TD] -5[/TD]
[/TR]
[TR]
[TD] 10[/TD]
[/TR]
[TR]
[TD][TABLE="width: 573"]
<tbody>[TR]
[TD]10.00 [/TD]
[TD]subtotal =SUBTOTAL(9,A2:A12)[/TD]
[/TR]
[TR]
[TD]-15.00[/TD]
[TD]negative hours =SUMIF(A2:A13,"<0")[/TD]
[/TR]
[TR]
[TD]35.00[/TD]
[TD]positive hours =SUMIF(A2:A13,">0")[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
[TR]
[TD]You can see that the subtotal is being added to the positive hours.[/TD]
[/TR]
</tbody>[/TABLE]
<strike></strike>
[TABLE="width: 573"]
<colgroup><col><col></colgroup><tbody>[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
<strike></strike>
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]=SUMIF(A2:A13,"<0")[/TD]
[TD]negative hours[/TD]
[/TR]
[TR]
[TD]=SUMIF(A2:A13,">0")[/TD]
[TD]positive hours[/TD]
[/TR]
</tbody>[/TABLE]
I want to sum both positive and negative hours in one column (start to finish) without including the subtotals. Any help would be much appreciated. Thank-you.
[TABLE="width: 400"]
<colgroup><col><col></colgroup><tbody>[TR]
[TD][TABLE="width: 1146"]
<colgroup><col><col></colgroup><tbody>[TR]
[TD][TABLE="width: 180"]
<colgroup><col></colgroup><tbody>[TR]
[TD] 1[/TD]
[/TR]
[TR]
[TD] -1[/TD]
[/TR]
[TR]
[TD] 2[/TD]
[/TR]
[TR]
[TD] -2[/TD]
[/TR]
[TR]
[TD] 3[/TD]
[/TR]
[TR]
[TD] -3[/TD]
[/TR]
[TR]
[TD] 4[/TD]
[/TR]
[TR]
[TD] -4[/TD]
[/TR]
[TR]
[TD] 5[/TD]
[/TR]
[TR]
[TD] -5[/TD]
[/TR]
[TR]
[TD] 10[/TD]
[/TR]
[TR]
[TD][TABLE="width: 573"]
<tbody>[TR]
[TD]10.00 [/TD]
[TD]subtotal =SUBTOTAL(9,A2:A12)[/TD]
[/TR]
[TR]
[TD]-15.00[/TD]
[TD]negative hours =SUMIF(A2:A13,"<0")[/TD]
[/TR]
[TR]
[TD]35.00[/TD]
[TD]positive hours =SUMIF(A2:A13,">0")[/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[/TR]
[TR]
[TD][/TD]
[/TR]
[TR]
[TD]You can see that the subtotal is being added to the positive hours.[/TD]
[/TR]
</tbody>[/TABLE]
<strike></strike>
[TABLE="width: 573"]
<colgroup><col><col></colgroup><tbody>[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
<strike></strike>
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]=SUMIF(A2:A13,"<0")[/TD]
[TD]negative hours[/TD]
[/TR]
[TR]
[TD]=SUMIF(A2:A13,">0")[/TD]
[TD]positive hours[/TD]
[/TR]
</tbody>[/TABLE]