LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default function question (sumif countif conditional)

Excel masters,
I have a question, in an excelsheet (office xp), I have the following data:
department score date moving average last 3 rows under
condition department a or b
....
a 8 1 jan 2008 ???
a 9 1 feb 2008
b 8 2 feb 2008
a 7 3 mar 2008
b 4 4 april 2008
a 5 may 2008
...and so on
The scorecell may be null.
How do I show the moving average in each row, (over the last six months or 3
rows with condition a or b). The problem is the condition department.
I looked at daverage but that doesnt work because the selection is not
contigious with the title.
Another solution is :
=SUMIF(OFFSET($A3;0;0;-3;1);2;B1:B1)/(COUNTIF(OFFSET($A3;0;0;-3;1);2))
This works but the scores may be null so the average is not good (wrong
count) if there is a null cell and the function countblank is not
conditional.
Excel 2007 has average.if but I work with xp
Alternative:
=IF(COUNTBLANK(OFFSET($B3;0;0;-3;1))=0;SUMIF(OFFSET($A3;0;0;-3;1);2;B1:B1)/(COUNTIF(OFFSET($A3;0;0;-3;1);2));"---").
This works but makes a "hole" in three rows if there is one empty cell.
Is there anothe handy function or solution, the analysis add-in doesnt work
either
Greetings and thanks, Norbert



 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
countif / sumif function error Mark J. Excel Worksheet Functions 3 May 4th 06 10:49 PM
Is there a function Countif that operates like Sumif? Undrline Excel Worksheet Functions 7 April 12th 06 05:55 AM
Conditional Summing (Sumif? Countif?) klam Excel Worksheet Functions 2 August 8th 05 07:39 PM
Question on Conditional COUNTIF Question on Conditonal Countif Excel Worksheet Functions 2 February 13th 05 07:29 PM
Countif/Sumif function question psyd Excel Worksheet Functions 0 November 5th 04 06:09 AM


All times are GMT +1. The time now is 11:28 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"