Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Apr 2015
    Posts
    6
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Using AVERAGEIF and OFFSET for the range

    Not quite sure how the OFFSET formula works, but I am using a dynamic column range I am trying to gather averages from. However, some cells will read 0%. I do not want to the formula to calculate the 0. I just want it to average any number that is greater than 0. What I have used for the average is:

    "=AVERAGE(E2: (OFFSET(E11,-1,0)))"

    This calculates all of the 0's as well. What can I do to use the offset formula as the range and not calculate the 0's?

    Ignore the space, but it added an emoji for when I post it.

  2. #2
    New Lounger
    Join Date
    Apr 2015
    Posts
    6
    Thanks
    2
    Thanked 0 Times in 0 Posts
    I ended up using this: =SUM((E2:(OFFSET(E11,-1,0))))/COUNTIF((E2:(OFFSET(E11,-1,0))), ">0")
    Last edited by RetiredGeek; 2015-05-14 at 10:43. Reason: Added Noparse tags

  3. #3
    WS Lounge VIP rory's Avatar
    Join Date
    Dec 2000
    Location
    Burwash, East Sussex, United Kingdom
    Posts
    6,280
    Thanks
    3
    Thanked 191 Times in 177 Posts
    It would be:
    =AVERAGEIF(E2:OFFSET(E11,-1,0),">0")
    Regards,
    Rory

    Microsoft MVP - Excel

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •