Using the Audiences feature involves several steps to create and send audiences to downstream systems, such as Facebook, Yahoo!, Google Analytics, and Nielsen. Previously, we covered how to define and execute attributes. The output from attribute execution serves as the input for defining an audience. This article explains how to use attributes to create audiences.
There are two ways to define an audience:
- Manual Creation: You define the audience by manually setting up the rules. For this, the 'Auto Extract' toggle on the screen should be OFF.
- Auto Extract: You let the system automatically extract the audience based on predefined rules. Enabling this will hide the option to define the audience manually.
In this article, we'll guide you through the process of manually creating an audience group, where you'll define attributes by setting specific rules. If you're looking to create an attribute group using the auto-extract feature, please refer to the article Creating Audience using Auto Extract. Now, let's dive into the key fields and steps required to manually create an attribute group.
Attributes
On the left side of the screen, you will find all the Attributes available under the data layer. These are actually attribute groups that include different attributes. These attributes contain the information we need to define the audience. When you select an attribute group, it opens up a list of its columns which are its attributes.
You can drag and drop any of these column names into the audience's fields (like the Left Value or Right Value) to create rules for the audience you’re building.
Note: When you drag and drop or select a column in rule conditions, the associated attribute group on the left-hand side is automatically selected. However, in code mode, you must manually select the attribute group by checking the box before saving the Audience Group.
Audience Group
On the Attribute Builder screen, you will see a field by the name Audience Group Name. This is the name you give to your set of audiences. It should clearly describe what kind of audience values are included in the group.
- Examples: An audience group may be a Brand, Brand Purchased, Brand Not Purchased, Product, etc.
Note: Since all attributes for a single data layer write results to the shared Audience result tables, the audience group name should be unique across all groups for the data layer.
Retention
Retention defines the number of days a visitor remains valid for an audience. This value is passed to the Audience Sync app(s) to determine if and when to send an audience downstream; however, it is not directly used to calculate or determine a visitor's qualification for an audience.
Audience Values
Once you've entered the Audience Group Name and set the Retention value, the next step is to define the individual Audience Values. If the Auto-Extract feature is disabled, you will need to manually configure each audience, including naming it and specifying the conditions under which the audience will be considered as "met."
Let’s walk through each component of the Audience Value configuration:
Audience Name
This unique name within the audience group should clearly describe the condition it checks. The conditions here consist of one or multiple attribute groups that either match or do not match a specific attribute value within the selected group. The Left Value represents the attribute group selection, the Right Value specifies the attribute value, and the Operator defines whether the audience should or should not match the chosen attribute group and value.
Audience Rules
Audience rules define the conditions under which the audience is triggered. These conditions can range from simple (like matching a single column value) to complex combinations of multiple conditions using AND/OR logic.
-
Requirements:
- At least one rule must be created to define an audience.
- You cannot create an Audience Group without at least one audience and its associated rules.
-
How to Add Rules:
- You can select column names from any attribute group available in the Data Layer.
- You also have the option to use the Function Editor to input custom values or logic.
- Use operators like equals (=), greater than (>), or contains to build conditions.
-
Drag-and-Drop Functionality:
- You can drag and drop column names(or attributes) from the attribute groups (shown on the left) directly into the fields for easy rule creation.
-
Auto-Generated Query:
- As you create or modify the audience's condition, an auto-generated query appears at the top, showing the current logic being applied.
Switch to code
The 'Switch to code' option allows you to manually edit the query logic by switching from the basic mode to code mode. You can click the "Switch to Code" icon to make the query editable in code format. In this mode, the simple column interface disappears, and you can directly write or modify the query.
Note: If you switch back to Basic Mode after editing the query in Code Mode, all changes made in Code Mode will be reversed. This happens because Code Mode allows for more complex queries than Basic Mode can handle.
Test icon
The Test icon allows users to execute the audience's query to preview how it will perform and estimate how many records meet the specified conditions before finalizing the audience. This feature provides valuable insights and helps ensure that the audience is working as expected. The system uses the date range specified in the Test Date Range field and the condition to evaluate the query. Here are the key benefits of using the Test feature:
- It helps in understanding the impact of the query.
- Allows refinement of the conditions based on the test results.
- Ensures the audience is accurate and effective before it is applied.
Example
Let's say you have two attribute groups:
- Product Purchases: This group includes details of visitors who purchased different products, such as TVs, laptops, etc.
- Payment Methods: This group contains details of visitors with the payment methods they used to purchase any product.
Suppose you have various discount offers tied to specific payment methods for the product "Fire TV Stick." For this, you want to target an audience who purchased a TV and used either a Credit Card or Debit Card for payment for any order on the platform.
To achieve this, you can create an Audience Group named "Payment Methods - TV Purchases". Within this group, create separate audiences for each payment method, for example:
- Credit Card - TV Purchases
- Debit Card - TV Purchases
The TV purchase data resides under the Product Purchases attribute group, while payment details are found in a separate attribute group. By applying an AND rule condition, you can combine the attributes to create an audience for each payment method used to buy a TV. This allows for precise targeting of users based on both their purchase and payment behavior.
When you run the job for Payment Methods - TV Purchases, the system will search for visitors who meet both conditions within the specified date range and record the results in the Audiences Results Table:
- Purchased a TV: Identified from the Product Purchases attribute group.
- Used a Credit Card for payment: Derived from the Payment Methods attribute group.
Input & Output Datasets
The Audience Builder screen includes two additional screens—Input Datasets and Output Datasets—accessible from the left side menu. The Input Datasets screen provides a preview of the input data with limited records, which can serve as a reference for decision-making when creating an attribute.
The Output Datasets screen displays the audience's results table generated after job execution. This audience can be sent to downstream systems, such as Facebook, Yahoo!, Google Analytics, and Nielsen by creating sync app. For more details on the output results table, see the article Audiences Results Table.