Excel 2013 Averageif function - Quotation marks?

Trying to figure out the logic behind the usage of quotation marks inside of a function.
Can someone explain, or give me a link to an article that explains the logic behind using quotation marks.
=average(a1:a99,">9")

When do I need them?  When do I not need to use them.
brothertruffle880Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Missus Miss_SellaneusCommented:
Are you sure that's not AVERAGEIF? If that was AVERAGEIF instead of AVERAGE, it would only use those cells which contain a value greater than 9.
0
brothertruffle880Author Commented:
oh crap.  yes.  it is average if.
I'm trying to understand when to use the quotes and when NOT.
I'm trying to understand WHY sometimes I need to place quotes in an argument.
I know how the function works and I know how to use it.  I'm just trying to figure out the logic of when I need quotation marks. Trying to understand the logic of the syntax of quotation marks.   IT seems kind of random when you use or not use the quotation marks.
0
Missus Miss_SellaneusCommented:
The only time you can omit the quotes is if you're matching on a number, not an expression and not text.

Here's an example with 3 different AVERAGEIF functions, highlighted in yellow:

1. =AVERAGEIF(A4:A10,"blue",B4:B10)   matches on text
2. =AVERAGEIF(D4:D10,1,E4:E10)             matches on the number 1
3. =AVERAGEIF(G4:G10,">=6",H4:H10)   matches if greater than or equal to 6

AVERAGEIF.JPG
0
Cloud Class® Course: CompTIA Cloud+

The CompTIA Cloud+ Basic training course will teach you about cloud concepts and models, data storage, networking, and network infrastructure.

crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
the reason quotation marks are needed is so that the AverageIf function does not get confused.  

> is an operator and has special meaning.

The quote marks delimit (mark, denote, ...) where the criteria starts and stops so the meaning is clear.

, might be in the criteria so it could not be used as a delimiter for arguments unless the criteria is clear (which is done with with marks)

> "When do I not need to use them"

The condition needs quotes.  If the criteria is a number, it will get implicitly delimited.  If the criteria is a cell reference, delimiters would not be used (but perhaps a function might surround the reference)

from Help, here is the syntax:

AVERAGEIF(range, criteria, [average_range])

The AVERAGEIF function syntax has the following arguments:

-- Range    Required. One or more cells to average, including numbers or names, arrays, or references that contain numbers.


-- Criteria    Required. The criteria in the form of a number, expression, cell reference, or text that defines which cells are averaged. For example, criteria can be expressed as 32, "32", ">32", "apples", or B4.


-- Average_range    Optional. The actual set of cells to average. If omitted, range is used.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
brothertruffle880Author Commented:
Thanks.
0
crystal (strive4peace) - Microsoft MVP, AccessRemote Training and ProgrammingCommented:
you're welcome ~ happy to help

warm regards,
crystal

~ have an awesome day ~
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Excel

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.