A common use case in reporting and data visualization is to display key performance indicators (KPI) as ratios of one indicator as compared to another. For example, suppose you are measuring the completion rate of an online coding academy. A KPI for the course is completion rate, which we'll define here as:
Course completions / Course registrations
If your data set already contains this data then you can simply display the result in Looker Studio. But what if you need to calculate it in your report, or need to display completion rates based on filtered data? The solution is to use data blending.
Say your data looks like this:
Event Category | Event Action | Course Number | Unique Events |
---|---|---|---|
Course Certificate | Download | 9 | 299 |
Course Complete | Fail | 8 | 21 |
Course Complete | Fail | 9 | 86 |
Course Complete | Pass | 9 | 337 |
Course Complete | Fail | 6 | 34 |
Course Complete | Pass | 7 | 363 |
Course Complete | Fail | 7 | 17 |
Registration | Register | 8 | 814 |
Registration | Register | 7 | 475 |
Registration | Register | 5 | 574 |
Registration | Register | 9 | 1078 |
Registration | Unregister | 6 | 22 |
Instructions
Calculate the course completions
- Add a scorecard to your report. Call it Course Completions.
- Set the metric to Unique Events.
- Add a filter to the scorecard to ignore non-completion events:
Include Event Category = "Course Complete"
AND
Include Event Action = "Pass"
Based on the sample data, the scorecard would look like this:
Course Completions 700 |
Calculate the course registrations
- Add a scorecard to your report. Call it Course Registrations.
- Set the metric to Unique Events.
- Add a filter to the scorecard to ignore non-registration events:
Include Event Category = "Registration"
AND
Include Event Action = "Register"
Based on the sample data, the scorecard would look like this:
Course Registrations 2,941 |
Blend the data from the scorecards
- Select the Course Registrations scorecard, then select the Course Completions scorecard.
- Right-click, then select Blend data.
This creates a new scorecard that automatically calculates the ratio between those metrics:
Course Completion Rate 23.80% |
- Select the blended scorecard.
- Edit the metric.
- Enter a new formula and/or change the field Type to match the data.
Related resources
Learn more about how blending works: