SOLVED

New Contributor

# Calculating averages in a table, based on two criteria

I have a table with different type of values in columns, where the two first columns is a date and the day of the week, followed by several columns with different values (e.g. sales).

I'm trying to calculate averages based on a specific weekday in a specific date range. For instance; I want to see the average of all Thursday's values during the last 4 weeks, or, the average of the Sunday's values during last month.

I'm able to create one of the two, i.e. the date range averages, or the weekday averages, but not the two in combination.

Suggestions?

4 Replies

# Re: Calculating averages in a table, based on two criteria

Use AVERAGEIFS() or a pivot table.

# Re: Calculating averages in a table, based on two criteria

I only get DIVISION/0 when using this. I need to enter a starting date and end date as a condition. However, I can't get it to accept a cell reference that should be higher/lower that a date specified in a cell outside the table. It is not allowed to enter ">" together with a cell reference.

Best Response confirmed by HenrikGd2o (New Contributor)
Solution

# Re: Calculating averages in a table, based on two criteria

It is not allowed to enter ">" together with a cell reference.

Sure it is allowed. Lookup the many tutorials on the web.

Use ">"&A2.

# Re: Calculating averages in a table, based on two criteria

I missed the '&' sign, and now it works.

Thank you!