View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Bob Phillips Bob Phillips is offline
external usenet poster
 
Posts: 10,593
Default average in excle

=AVERAGE(IF(A2:A100=Job),B2:B100))

which is an array formula, it should be committed with Ctrl-Shift-Enter, not
just Enter.
Excel will automatically enclose the formula in braces (curly brackets), do
not try to do this manually.
When editing the formula, it must again be array-entered.

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Toppers" wrote in message
...

=SUMPRODUCT(--(A2:A100=Job),B2:B100))/SUMPRODUCT(--(A2:A100=Job)

=SUMIF(A2:A100,job,B2:B100)/COUNTIF(A2:A100,job)

where Job is Job Title (text) OR cell containing Job Title

" wrote:

I'm raking my brains...I have a table where column A has job titles,
column B has the salary. Column A has duplicate job titles, which is
OK, what I'm looking for is an average function that will give me the
average salary per job title. I know I could do this via a pivot
table but I was planning on using vlookup and/or average. I'm just
not getting the syntax correct. Any help?