The most important formula in Klipfolio
There are four functions in Klipfolio Klips to understand and master early: SLICE, SELECT, GROUP/GROUPBY, and LOOKUP. These Data Manipulation Functions come together into what can fairly be called the single most important formula in Klipfolio Klips. Learn how each parameter works, why GROUP prevents incomplete data, and how LOOKUP aligns your series to the X axis so your charts show numbers you can actually trust.
New users sometimes get frustrated when a Klip or formula in Klipfolio Klips doesn't come together on the first try. Templates look simple, so building a dashboard from scratch feels like it should be just as simple.
It generally isn't. There's a learning curve, and the payoff for climbing it is real: once you understand how a handful of functions work together, you can answer questions from your data that would otherwise take hours to untangle manually.
If you're just getting started, or you want a quick refresher, there are four functions in Klipfolio Klips to learn early: SLICE, SELECT, GROUP/GROUPBY, and LOOKUP.
These Data Manipulation Functions come together into what can fairly be called the single most important formula in Klipfolio Klips.
Here it is:
Data source that it uses:
Klip that it built:
The LOOKUP function
The key to mastering this, and all functions, is understanding parameters. Each function has a set number of parameters. Each parameter expects a certain kind of data and performs a specific action.
Take LOOKUP. It has three parameters, and each one does a distinct job.
LOOKUP
Parameter one: X axis
This is a reference to the X axis of the Klip, containing various states in the U.S. Think of it as a long list of values.
Parameter two:
Think of this as a second list of values. In this case, it's not all states (B:B) from the X axis, but only those with an order (F:F) that is Delayed.
Create custom dashboards for you and your team.
Get started with KlipsParameter three:
Here, you're looking at the states (B:B) that have delayed orders (F:F), and totalling the value (E:E) of those delayed orders.
The LOOKUP function takes a list of values (first parameter), looks for matches in a second list (second parameter), and, where there's a match, returns a corresponding data set (third parameter). In the example, of the 20 states on the X axis, only nine have delayed orders. LOOKUP aligns the numerical data from the series with the correct state on the X axis, so you get an accurate picture without manually reconciling rows.
Parameter one (closer look): X axis
When using LOOKUP to align data to the X axis, parameter one is often a reference to the X axis values. This gives all X axis data and sets up the alignment of numerical data to the correct points. Use a Reference (third button on the formula toolbar, REF) to reuse a formula you built elsewhere in the Klip. It saves time. Note that referencing the X axis recalculates the entire formula, so it's a time-saver, not a performance shortcut.
Parameter two (closer look):
Think of this as a second list of values. Here, it's not all states (B:B) on the X axis, but only those with an order (F:F) that is Delayed.
Parameter two adds some complexity. This data needs to return matches to at least some items on the X axis: states. You only want the states with delayed orders, so use SELECT to specify a simple condition: "F:F = Delayed." If you only use this SELECT statement and leave out GROUP, you're left with this data:
You see the 42 items in the data source where the orders are delayed, with many repeating values.
LOOKUP searches for matches in this list and stops once it finds one. So when it arrives at the first record for "Washington," it matches an X axis data point, moves on to the third parameter, and uses the value for that Washington order. It ignores the four other Washington matches and moves to the next state. The result is incomplete data and a chart you can't trust.
This is why GROUP is used.
With the list of states with delayed orders GROUPed to remove duplicates, LOOKUP can identify a single match per state. The numbers become reliable. That's the point: not just a cleaner formula, but a chart your team can act on.
Parameter three (closer look):
This approach starts with a reference to the X axis (all states), looks for matches in a smaller set that meets a condition (some states), and, where a match is found, runs this formula.
GROUPBY lets you perform calculations on GROUPed data. Here, the goal is to calculate the value of delayed orders totalled by state where delayed orders exist.
GROUPBY uses three parameters: values, measure, and method.
The first parameter in GROUPBY is the data being grouped. Treat this as a rule. Often you can copy the formula from an X axis, or another part of your Klip, and paste it here.
If you look at the complete formula again, the GROUP function is identical to the first parameter of the GROUPBY function (red underlines). Don't include GROUP inside GROUPBY, since GROUPBY performs that calculation. Reuse the entire contents of GROUP.
The second parameter of GROUPBY is very similar, so copying it often makes sense. It's also a SELECT statement, with the same condition.
Remember the three parameters of GROUPBY: (data you are grouping) (data being calculated) (type of calculation, leave blank to SUM by default).
To finish GROUPBY, SELECT the data from E:E (number of units) where F:F (order status) is delayed. The SELECT statement is identical, but swap B:B (from the first part of GROUPBY) for E:E.
Create custom dashboards for you and your team.
Get started with KlipsUnderstanding the LOOKUP formula
The formula looks complex at first. Once you understand the number of parameters in each function, and what each parameter needs and does, you can break it into manageable pieces.
This pattern shows up often when building dashboards in Klipfolio Klips. Master it and you'll spend less time wrestling with formulas and more time reading numbers you can actually trust, whether you're building a Sales Dashboard, tracking delayed orders, or answering a question your team keeps asking manually.
Published 2026-09-02
More in Dashboards
The Ultimate Klipfolio Cheat Sheet
Building custom HubSpot reports and dashboards with Klipfolio
Display poll results with a pie chart
7 SQL query performance tuning tips
How to use Marketo data to build a dashboard your team can monitor
Google Sheets: Best practices to prepare your data for your dashboard
Most recent
- AUG 11Beyond simple sign-ups: how True Trials and Activation predict growth
- JUL 7Why business leaders miss important trends in their dashboards
- JUN 19The best chart for the job: Visualizing data for non-technical users
- JUN 95 tips to understand (and organize) your restaurant data
- MAY 26Think in Horizons, Not Seconds
- MAY 2010 cloud BI dashboard tools for growing firms in 2026