Wednesday, February 22, 2006

Average of n samllest or n biggest numbers from a list

To calculate the average of n biggest numbers from a list enter this formula with Ctrl + Shift + Enter:
=AVERAGE(IF(RANK(yourrange,yourrange)<=n,yourrange,""))

To calculate the average of n smallest numbers from a list enter this formula with Ctrl + Shift + Enter:
=AVERAGE(IF(RANK(yourrange,yourrange)>COUNT(yourrange)-n,yourrange,""))


For an example:

Comments: Post a Comment

Links to this post:

Create a Link



<< Home

This page is powered by Blogger. Isn't yours?