# Insights

> Source: https://docs.recombee.com/insights

> For the complete documentation index, see [llms.txt](/llms.txt).

**Table of contents**

* [Video Tutorial](#video-tutorial)
* [Library of Predefined Insights](#library-of-predefined-insights)  
   * [Predefined Insight Types](#predefined-insight-types)  
         * [Performance Metrics](#performance-metrics)  
         * [Top Items](#top-items)  
         * [Category-Based Metrics](#category-based-metrics)  
         * [Item-Segment Based Metrics](#item-segment-based-metrics)
* [Creating Custom Insights](#creating-custom-insights)  
   * [Insight Types](#insight-types)  
   * [Insights Settings](#insights-settings)  
   * [Data Sources](#data-sources)  
         * [Available Data Sources](#available-data-sources)  
                  * [Recommendations Data Sources](#recommendations-data-sources)  
                  * [Interactions Data Sources](#interactions-data-sources)  
                  * [Interactions Based on Recommendations Data Sources](#interactions-based-on-recommendations-data-sources)  
         * [Ratio Data Sources](#ratio-data-sources)  
   * [Filters](#filters)  
         * [Example - The CTR of a Scenario](#example-the-ctr-of-a-scenario)  
         * [Example - The Most Recommended Items from a Category](#example-the-most-recommended-items-from-a-category)  
         * [Data Source Specific Filters](#data-source-specific-filters)  
                  * [Example - Total Number of Detail Views and Number of Detail Views for Items from a Category](#example-total-number-of-detail-views-and-number-of-detail-views-for-items-from-a-category)  
                  * [Example - The Ratio of the Number of Viewed Items from a Category on All the Views of Items](#example-the-ratio-of-the-number-of-viewed-items-from-a-category-on-all-the-views-of-items)  
   * [Splits](#splits)  
         * [Example - Count of Recommendation Requests Split by Used Scenario](#example-count-of-recommendation-requests-split-by-used-scenario)  
         * [Example - Count of Recommended Items Split by Their Genres Item Property](#example-count-of-recommended-items-split-by-their-genres-item-property)  
         * [Example - Sum of Price of Purchases Based on Recommendations Split by Scenario and User ID](#example-sum-of-price-of-purchases-based-on-recommendations-split-by-scenario-and-user-id)  
         * [Sorting & Number of Results](#sorting-number-of-results)  
                  * [Sort Direction](#sort-direction)  
                  * [Number of Results](#number-of-results)  
                  * [Splits on Multiple Data Sources](#splits-on-multiple-data-sources)  
         * [Splitting by Item Property of the Type Set](#splitting-by-item-property-of-the-type-set)  
                  * [Example](#example)

# Insights

Insights allow you to take a deep dive into your data.

![](/img/insights/main.png) 

You can explore what items are the most recommended, which categories of items are being interacted with thanks to recommendations, or what portion of views is based on previous successful recommendations.

## Video Tutorial

## Library of Predefined Insights

We have created a library of Insights covering frequently used analytical data views.

[![Recombee Insights Library](/img/insights/recombee-library.png)](/img/insights/recombee-library.png)

### Predefined Insight Types

For easier orientation we group the predefined Insights in the library into the following groups.

#### Performance Metrics

* Metrics such as Click Through Rate, Cart Conversion Rate, or Conversion Rate

#### Top Items

* Insights showing the top items according to various metrics
* For example the most recommended items, the most interacted items, or the items that are the most clicked in the recommendation boxes

#### Category-Based Metrics

* These Insights group the recommended or interacted items by their category item property
* You can therefore see which categories are the most interesting for users, either thanks to recommendations or in general

#### Item-Segment Based Metrics

* Similarly to grouping by the category item property, you can also group the recommended or interacted items by any [Items Segmentation](/segmentations) that you use in your Database  
[![Top Items Insight with the most recommended items per scenario](/img/insights/top-items.png)](/img/insights/top-items.png)  
Top Items Insight with the most recommended items per scenario

## Creating Custom Insights

One of the best ways to start with custom Insights is to duplicate an existing Insight from the library and change particular settings.

However, you can also start entirely from scratch by clicking the **Create Insight** button.

### Insight Types

You can choose from the following types of visualization.

![Bar Chart](/img/insights/type-bar-chart.png)

Bar Chart

![Line Chart](/img/insights/type-line-chart.png)

Line Chart

![Area Chart](/img/insights/type-area-chart.png)

Area Chart

![Table](/img/insights/type-table.png)

Table

![Top Items](/img/insights/type-top-items.png)

Top Items

Shows a list of e.g., most recommended, interacted, or profitable items

### Insights Settings

**There are three main settings:**

**[Data Sources](#data-sources)** \- What kind of data and what metric will be used (e.g., _Count of Recommended Items_ or _Sum of Price of Purchases Based on Recommendations_).

**[Filters](#filters)** include only particular data in the result (e.g., show data only for a particular Item, for a particular Scenario, or for a category).

**[Splits](#splits)** break down the data by fields (e.g., by Scenario or per a property such as category).

### Data Sources

The Data Source **describes the queried data and applied metric**. Some examples can be the _Count of Recommended Items_ or the _Average price of Purchases_.

It also defines what [Filters](#filters) and [Splits](#splits) can be applied - for example, recommendation requests can be filtered per a Scenario, while the [Rating interactions](/api#add-rating) can be filtered to positive or negative ratings based on the submitted value.

You can add **multiple Data Sources** to your Insight. If you add multiple Data Sources,then only the [Splits](#splits) that are applicable to all the Data Sources can be added.

#### Available Data Sources

The available Data Sources can be categorized by their topic into the following 3 groups:

* Recommendations
* Interactions
* Interactions Based on Recommendations

[![Picking a Data Source](/img/insights/picking-a-data-source.png)](/img/insights/picking-a-data-source.png)

Picking a Data Source

##### Recommendations Data Sources

Data Sources from this category present data about:

* **Recommendation Requests**  
   * Recommendation requests sent to the Recombee API  
   * Based on the selected _Metric_, you can see for example the count of the requests or the number of distinct users that requested the recommendations
* **Recommended Items / Recommended Users / Recommended Item Segments**  
   * The individual Items / Users / [Items Segments](/segmentations) that were recommended  
   * Based on the selected _Metric_, you get for example the total count of recommended Items or the number of distinct recommended Items

![The difference between Recommendation Requests and Recommended Items](/img/insights/ask-for-recommendations.png)

The difference between Recommendation Requests and Recommended Items

##### Interactions Data Sources

Data Sources in this category present data about ingested interactions.

* **Individual interaction types: Detail Views / Ratings / Purchases …**  
   * Interactions of a particular type  
   * All the Data Sources offer _Metrics_ like count, count of distinct users, or count of distinct items  
   * Particular interaction types offer specific _Metrics_ \- for example, _Purchases_ offer Price (with operators such as sum or maximum), while _Ratings_ offer the value of the rating (so you can see e.g., average rating)
* **All interactions**  
   * Interactions of all types together

View Portions vs. View Portion Events

The **View Portion** Data Source aggregates the ingested View Portions by sent (User, Item, Session).

Therefore, if the user watches a video and you send 5 milestones to Recombee, it will still be counted as a single View Portion. This way, the View Portions are shown in the KPI console and counted in the _All Interactions_ Data Source and also in pricing.

The **View Portion Events** Data Source contains each Set View Portion request sent to the API. Therefore, if the user watches a video and you send 5 milestones to Recombee, there will be 5 View Portion Events.

![View Portion / View Portion Events comparison](/img/insights/insights-view-portions.png)

View Portion / View Portion Events comparison

##### Interactions Based on Recommendations Data Sources

Data Sources in this category present data about interactions that happened **thanks to previous successful recommendations**.

Their types follow the same pattern as [Interactions](#interactions-data-sources).

You can see either [Reported (based on sent recommId) or Estimated (based on time window) Interactions Based on Recommendations](/admin_ui#success-metrics-in-kpi).

#### Ratio Data Sources

When adding a Data Source, you can switch from a _Simple Data Source_, which shows a single metric, to a _Ratio Data Source_, which is a ratio of two Data Sources.

The Ratio Data Source can be used for showing various percentual metrics, such as:

**Click-Through-Rate**

* Numerator - _Count of Detail Views Based on Recommendations_
* Denominator - _Count of Recommendation requests_

![](/img/insights/ctr-ratio.png)

**Ratio of profit from recommendations on the total profit**

* Numerator: _Profit of Purchases Based on Recommendations_
* Denominator: _Profit of all Purchases_

**Ratio of recommended items from a category on all recommended items**

* Numerator: _Count of Recommended Items_ with a [Filter](#filters) set to a particular category
* Denominator: _Count of Recommended Items_

[![Example of setting up a Ratio Data Source](/img/insights/data-source-settings.png)](/img/insights/data-source-settings.png)

Example of setting up a Ratio Data Source

### Filters

The Filters allow you to include only part of the data in the Insight, or exclude it.

You can see the data for example, only for a particular Scenario, for a particular User, or for a particular [Segment](/segmentations) of your data (e.g., one category).

You can either add a Filter in the Filters section or click on a value in the graph or table and choose to include it or exclude it.

[![Adding a Filter directly in the table](/img/insights/filter-in-table.png)](/img/insights/filter-in-table.png)

Adding a Filter directly in the table

##### Example - The CTR of a Scenario

Add a Filter on a particular Scenario.

[![The CTR of a Scenario](/img/insights/ctr-of-a-scenario.png)](/img/insights/ctr-of-a-scenario.png)

##### Example - The Most Recommended Items from a Category

Add a Filter on an Item Property, choose the _category_ property, and fill in the name of a particular category.

[![The Most Recommended Items from a Category](/img/insights/most-recommended-items-from-category.png)](/img/insights/most-recommended-items-from-category.png)

#### Data Source Specific Filters

By default, the Filters are applied to all the Data Sources. However, you can also add a Filter only to a particular Data Source.

In the case of the [Ratio Data Sources](#ratio-data-sources), you can also choose whether to apply the Filter to both numerator and denominator or only one of them.

##### Example - Total Number of Detail Views and Number of Detail Views for Items from a Category

You can add the _Count of Detail Views_ Data Source twice (with an _Alias_ to distinguish them), and for one of them, set the Filter.

_Data Sources_

![](/img/insights/data-source-specific-filters-example-1-1.png)

![](/img/insights/data-source-specific-filters-example-1-2.png)

_Filter_

![](/img/insights/data-source-specific-filters-example-1-3.png)

Which yields the following result

![](/img/insights/data-source-specific-filters-example-1-4.png)

##### Example - The Ratio of the Number of Viewed Items from a Category on All the Views of Items

This Insight is set as a [Ratio Data Source](#ratio-data-sources), where both the numerator and denominator are set to the Count of Detail Views, and the Filter on a category is applied to the numerator.

_Data Source_

![](/img/insights/data-source-specific-filters-example-2-1.png)

_Filter_

![](/img/insights/data-source-specific-filters-example-2-2.png)

The result is the portion of the views of Items from the particular property on all the views

![](/img/insights/data-source-specific-filters-example-2-3.png)

### Splits

A Split breaks down the data by a field. The field must be available in all the added Data Sources.

#### Example - Count of Recommendation Requests Split by Used Scenario

Adding Split on Scenario shows the number of requests per Scenario.

![](/img/insights/splits-example-1-1.png)

**↓**

![](/img/insights/splits-example-1-2.png)

#### Example - Count of Recommended Items Split by Their Genres Item Property

Adding the Split on Item Property called `genres` shows the number of recommended items (in this case movies) per their genre.

![](/img/insights/splits-example-2-1.png)

**↓**

![](/img/insights/splits-example-2-2.png)

#### Example - Sum of Price of Purchases Based on Recommendations Split by Scenario and User ID

This Insight **requires two Splits:**

* The first one **on Scenario**

![](/img/insights/splits-example-3-1.png)

* The second one **on the User ID**

![](/img/insights/splits-example-3-2.png)

It works in the way that first the Scenarios with the highest _Sum of Price of Purchases Based on Recommendations_ are selected.

For each of these top Scenarios, results for users with the highest _Sum of Price of Purchases Based on Recommendations_ within the Scenario are presented.

![](/img/insights/splits-example-3-3.png)

You can see that the order of the Splits matters: If you added the Split on _User_ first and then the Split on _Scenario_, the top Users according to _Sum of Price of Purchases Based on Recommendations_ would be selected (no matter the Scenarios), and for these users the sum of price would be split by the Scenario of the successful recommendation.

![](/img/insights/splits-example-3-4.png)

You can drag & drop the Splits in the list to change their order.

#### Sorting & Number of Results

##### Sort Direction

By default, the resulting split groups are ordered by the _Metric_: For example, in the case of _Count of Recommendation Requests_ Data Source and split by Scenario, you will get the Scenarios with the highest number of recommendation requests during the time period (in descending order by the count).

![](/img/insights/splits-sort-1.png)

If you would instead want to order by the values from the Split themselves, in this case, the Scenarios, you can change the _Sort Direction_ to _Ascending_ or _Descending_, and you will get Scenarios ordered alphabetically in ascending or descending order.

![](/img/insights/splits-sort-2.png)

**↓**

![](/img/insights/splits-sort-3.png)

##### Number of Results

You can limit the number of groups produced by the Split by setting the _Max Groups_ parameter (default: 10). It will show at most this number of top groups according to the _Sort direction_.

If there are more groups in the data than _Max Groups_, you can see the aggregate of all the other groups by enabling the _Other Group_ option.

![](/img/insights/splits-number-of-results.png)

##### Splits on Multiple Data Sources

If you have multiple [Data Sources](#data-sources), then their order matters: The Split groups are picked according to the first Data Source in the list.

For example, if you have two Data Sources: _Recommendation Requests_ and _Detail Views Based on Recommendations_ with a Scenario Split, then the Scenarios with the highest count of _Recommendation Requests_ are selected, and for these Scenarios the count of _Detail Views Based on Recommendations_ is displayed.

![](/img/insights/splits-multi-data-sources-1.png)

If the Data Sources were in a different order: _Detail Views Based on Recommendations_ first and _Recommendation Requests_ second, then the picked Scenarios depend on the number of _Detail Views Based on Recommendations_.

![](/img/insights/splits-multi-data-sources-2.png)

You can drag & drop the Data Sources in the list to change their order.

#### Splitting by Item Property of the Type Set

If you split by an [Item Property](/api#add-item-property) of type set (which contains multiple values), or by a [Segmentation](/segmentations) that gives multiple Segments for an Item, the Item is counted towards each yielded item property value / Segment.

##### Example

Assume _Count of Recommended Items_ Data Source:

![](/img/insights/splitting-by-item-property-example-1.png)

If there are Items with their _genres_ property set to `{"action", "science_fiction"}`, then after adding the Split on the genres property, those Items are counted towards both _genres_:

![](/img/insights/splitting-by-item-property-example-2.png)