Formulas You Should Know | IF

Excel, or Google Sheets if you prefer, are both powerful tools for digital marketers. They not only let us visualize data in graphs and charts, but they have loads for formulas built in to further refine the type of analysis we can do and the speed at which we can draw insights.

One formula that looks scary but has a ton of power behind it is the IF statement. The statement itself looks like this:

=IF(logic check,value to return when logic is true, value to return when logic is false)

What it does is checks for a specific condition, and if that condition is true, returns a value. When the condition is false, it returns a different value. Here’s an example if we wanted to check whether sales are at or above $500M in a given quarter.

=IF([cell to check value of]>499, “Y”, “N”

Quarter Total Sales ($m) Quarter above $500m
Q1 $450 N
Q1 $505 Y
Q3 $550 Y
Q4 $450 N

This is a simple example, but the opportunities are vast for the IF statement. Here is another useful real-life situation I’ve found valuable.

Scenario

You have a set of data with a wide variance in values.

Application of IF statement

Use the IF statement to group values into logical buckets for your business. Say you wanted to separate products with less than $100M in sales from products with more than $100M in sales. You could do something like this…

=IF([cell to check value of]>99, “Greater than $100 in sales”, “Less than $100 in sales”

SKU Total Sales ($m) Sale Bucket ($m)
A123 $5 Less than $100 in sales
B123 $25 Less than $100 in sales
C123 $500 Greater than $100 in sales
D123 $101 Greater than $100 in sales

When you consider a real data set that would have thousands of SKUs and could be broken down further by time range – using the IF statement to group sales into buckets can be very useful – especially if you plan on taking it ot a pivot table.

A few other examples for useful applications of the IF statement involve nesting, so we’ll save those for later – after we talk about nesting.

Any IF statements scenarios that have made your life easier – tell us about them.

One Comment

  1. Pingback: Formulas You Should Know | SUMIF - A Real Marketer

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.