Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Creating daily average from multiple values per day

I've got a dataset with measurements at different time intervals per day.
Most are on the hour, so I could just create daily average for each 24
entries, but many have more (or less) per day. How do I create a daily
average of each group of numbers per day? The data is formatted as column
A=date, column B=amount
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,358
Default Creating daily average from multiple values per day

=IF(COUNTIF(A1:A8,A11)=0,"No Data",AVERAGE(IF(A1:A8=A11,B1:B8)))
A1:A8 is the dates (note, more work is needed if this is actually date and
time, but if it is just a date, this will work.
A11 is the date you are wanting to average
B1:B8 is the amount
This is an **array** formula, and must be entered with CTRL+Shift+Enter
--
** John C **

"ser1609" wrote:

I've got a dataset with measurements at different time intervals per day.
Most are on the hour, so I could just create daily average for each 24
entries, but many have more (or less) per day. How do I create a daily
average of each group of numbers per day? The data is formatted as column
A=date, column B=amount

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2
Default Creating daily average from multiple values per day

Thanks John, it seems close (the first date was correct), but this dataset is
over 50,000 entries with thousands of dates. Can this be modified to
calculate the daily average of every distinct date in the set?

"John C" wrote:

=IF(COUNTIF(A1:A8,A11)=0,"No Data",AVERAGE(IF(A1:A8=A11,B1:B8)))
A1:A8 is the dates (note, more work is needed if this is actually date and
time, but if it is just a date, this will work.
A11 is the date you are wanting to average
B1:B8 is the amount
This is an **array** formula, and must be entered with CTRL+Shift+Enter
--
** John C **

"ser1609" wrote:

I've got a dataset with measurements at different time intervals per day.
Most are on the hour, so I could just create daily average for each 24
entries, but many have more (or less) per day. How do I create a daily
average of each group of numbers per day? The data is formatted as column
A=date, column B=amount

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,358
Default Creating daily average from multiple values per day

Where do you want the data? This works just fine for me.
=IF(COUNTIF($A$2:$A$50000,A2)=0,"No
Data",AVERAGE(IF($A$2:$A$50000=A2,$B$2:$B$50000)))
Again, entered as an **array** formula. You could even modify it so that the
average ONLY appears once, the first occurance of the date, the last
occurance of the date, etc.
--
** John C **

"ser1609" wrote:

Thanks John, it seems close (the first date was correct), but this dataset is
over 50,000 entries with thousands of dates. Can this be modified to
calculate the daily average of every distinct date in the set?

"John C" wrote:

=IF(COUNTIF(A1:A8,A11)=0,"No Data",AVERAGE(IF(A1:A8=A11,B1:B8)))
A1:A8 is the dates (note, more work is needed if this is actually date and
time, but if it is just a date, this will work.
A11 is the date you are wanting to average
B1:B8 is the amount
This is an **array** formula, and must be entered with CTRL+Shift+Enter
--
** John C **

"ser1609" wrote:

I've got a dataset with measurements at different time intervals per day.
Most are on the hour, so I could just create daily average for each 24
entries, but many have more (or less) per day. How do I create a daily
average of each group of numbers per day? The data is formatted as column
A=date, column B=amount

  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,344
Default Creating daily average from multiple values per day

Hi,

Here are three different ways

1. in 2007 =AVERAGEIF(A1:A50000,C1,B1:B50000)
2. =SUMIF(A1:A50000,C1,B1:B50000)/COUNTIF(A1:A50000,C1)
3. =AVERAGE(IF(A1:A50000=C1,B1:B50000))

The second and third ones work in all versions. The third one requieres
array entry. If you are going to copy you should make the references
absolute as needed.

--
Thanks,
Shane Devenshire


"ser1609" wrote:

I've got a dataset with measurements at different time intervals per day.
Most are on the hour, so I could just create daily average for each 24
entries, but many have more (or less) per day. How do I create a daily
average of each group of numbers per day? The data is formatted as column
A=date, column B=amount

Reply
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
Average of multiple range with error values Werner Rohrmoser Excel Worksheet Functions 5 January 4th 08 01:47 PM
Creating graph from values in multiple tabs within workbook roger lewis Charts and Charting in Excel 4 June 24th 07 02:45 PM
Calculate the average of numbers, ignoring multiple values Quintessence Excel Discussion (Misc queries) 2 May 30th 07 04:35 PM
Average Values / Multiple Worksheets George Reis Excel Worksheet Functions 5 January 31st 06 10:27 PM
creating drop down lists where you can select multiple values Angella Excel Discussion (Misc queries) 2 April 23rd 05 04:58 PM


All times are GMT +1. The time now is 07:16 PM.

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

About Us

"It's about Microsoft Excel"