简体   繁体   中英

Average count of rows based on time range

I have a sheet (Data) with a year's worth of inquiries received like the below table;

Time     Status    Analyst   Client Category Incident#      Date        VIP   
03:03:28 Closed    John      XXX    A         72321         18/11/2015  TRUE
20:15:09 Resolved  Frank     ABC    A         73425         19/12/2015  FALSE
14:29:45 Closed    Joyce     DEF    B         74432         2/2/2016    FALSE
03:01:18 Closed    Adam      XYZ    D         73675         4/6/2016    TRUE
23:58:54 Resolved  John      XXX    G         75335         9/4/2016    TRUE

I'm trying to calculate the average count of rows based on whether that row falls into a particular range. For example what's the average number of entries received between 3am and 4am, or the average number of entries received on a Monday. I was leaning towards an averageifs formula but that is averaging the value within the range I select as they contain a numeric value rather than averaging the count of those entries.

EDIT: The formula I'm using is;

=AVERAGEIFS(Data!C:C,Data!$A:$A,">="&'Sheet I'm calculating in'!(cell with value of 3am),Data!$A:$A,"<"&'Sheet I'm calculating in'!(cell with value of 4am))

I've selected the Column C to show that I do not want the average of cells with numeric values, just the average count of rows for that time range. If I select column A or F for example it gives me the average of those numeric values.

I'm looking for the average number of inquiries received between 3am and 4am for the whole year.

Thanks in advance.

Use of Pivots will solve the problem, in a easier way. You can use the above link to learn about pivot http://www.excel-easy.com/data-analysis/pivot-tables.html

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM