I am trying to change the text of a cell in Numbers 3 according to a condition. E.g. if A1-A2 is a negative value, the text shall be 'Negative'. If the value is positive the text shall be 'Positive'. Is there something like a function to accomplish this?

1 Answer 1


You can do this with the IF function. The syntax is…

┌── IF function returns one of two values when upon an expression's evaluation.
│                     ┌── string or calculation for cell to show upon TRUE/FALSE
│                     │   strings should be inside double quotes "like this"
│                ┌────┴─────────┐
         └── the expression to evaluate
             for example: to test if A1-A2 is negative, you can use (A1-A2)<0
             the result must be a boolean

This results in the following calculation:



An example for comparing a calculation in the if-expression:

            ┌── from table "Data" do A1-B1
            │          ┌── is the result less than zero (i.e. negative)?
    ┌───────┴───────┐  │
                         └───┬────┘ └───┬────┘
                             │          └── if false, return "Positive"
                             └── if true, return "Negative"


However, this will return Positive even if the number is 0, so instead…

            ┌── from table "Data" do A1-B1
            │          ┌── is the result less than zero (i.e. negative)?
    ┌───────┴───────┐  │
                         └───┬────┘                        │ └─┬──┘ └────┬───┘
if true, return "Negative" ──┘           is equal to 0? ───┘   │  return "Positive"
                                                               └── return "Zero"

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .