# What is the proper way to calculate an average with two columns of data?

I saw a post on the internet about this a long time ago and can't seem to find that post again. The post talked about the proper way to calculate an average if the data was in two columns and the solution wasn't intuitive. Perhaps someone here can provide guidance.

I'm trying to calculate the average amount of time it takes to document a business process. My data set looks like this

    process_id, num_rows_of_data, completion_time (in minutes)
1,9,34
2,4,21
3,56,144
4,78,43
5,17,27


I'm trying to calculate the average number of minutes it takes to document a single row of data. I think most people would say

average = sum(completion_time) / sum(num_rows_of_data)

But that seems too simple to be correct.

• That's the average per row. If you want the average per process, you ignore number of rows. The decision between them is up to you. It's like how many books owned per household or how many books owned per person: both seem meaningful, and it's just a question of which is more interesting or useful. – Nick Cox May 5 '15 at 0:07
• That being the case, then the answer is really just grade school arithmetic no? average = average((sum(completion_time)) – Bob May 6 '15 at 16:23
• There are two possible averages, weighted and unweighted, I can't say which you want. – Nick Cox May 6 '15 at 16:32
• I don't think weighting will be useful. While I am capturing the number of rows, what we really want to know is by process. – Bob May 7 '15 at 17:12