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 Calculate average of ratings as a function of length

I have roadway segments that have been rated 1-5. Each segment has a
different length. I want to calculate the average rating for the total
length. How do I do that and make it a function of length. example:
road A has a rating of 5 and is 3 miles long
road B has a rating of 3 and is 1 miles long
road C has a rating of 2 and is 2 miles long

What is the average rating?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 11,058
Default Calculate average of ratings as a function of length

3.666666667
--
Gary''s Student - gsnu200753
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4,393
Default Calculate average of ratings as a function of length

This is called a 'weighted average'
For your data use (3*5 + 1*3 + 2*2) / (3+1+2) to get average rate
You could have a column next to miles and rates to compute miles*rate
then add this and divide by sum(miles)
But it can be done in one cell: If miles are in A1:A3, rates in B1:B3 the
formula
=SUMPRODUCT(A1:A3,B1:B3)/SUM(A1:A3)
will give the answer
best wishes
--
Bernard V Liengme
Microsoft Excel MVP
www.stfx.ca/people/bliengme
remove caps from email

"rodeo" wrote in message
...
I have roadway segments that have been rated 1-5. Each segment has a
different length. I want to calculate the average rating for the total
length. How do I do that and make it a function of length. example:
road A has a rating of 5 and is 3 miles long
road B has a rating of 3 and is 1 miles long
road C has a rating of 2 and is 2 miles long

What is the average rating?



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
ratings Allllen Excel Discussion (Misc queries) 2 January 31st 07 09:34 PM
formula help: calculate length of employment Mharper Excel Worksheet Functions 2 March 29th 06 04:47 PM
Calculate the average using the Lookup function or similar Lars F Excel Discussion (Misc queries) 2 November 22nd 05 11:40 AM
calculate the number of words in a row whose length is greater than 2 sks1379 Excel Worksheet Functions 5 September 4th 05 06:21 PM
How can I calculate Vacation Time earned based on length of emplo. Kim Excel Discussion (Misc queries) 2 March 15th 05 08:04 PM


All times are GMT +1. The time now is 08:54 AM.

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

About Us

"It's about Microsoft Excel"