Snapshot Datasets: Comparing Instances (older versions)

While the Video Tutorial is still valid and useful, newer versions of Metric Insights also allow you to find rows that have been changed in addition to those added or removed.

See Snapshot Datasets: Comparing "Last Two Instances" / Track Changes (Version 5.0.5)

The following article describes how to track changes in paired datasets instances.

This article answers the following questions:


Video Tutorial

This option is only available for Views of Snapshot Datasets

If in the Dataset Editor > Data tab the Snapshot dataset? field is set to 'yes', than in the Dataset Viewer  the following options available:

  • Reviewing a Single Instance of this Dataset (for example, yesterday), or
  • Tracking changes in the Last Two Instances of this Dataset (for example, yesterday's data compared to what occurred the day before yesterday).

NOTE: You can compare ANY instance saved during previous data collections to its instance collected the day before.

1. Choose the date that you want to compare to the prior one

Example: In the example, we choose the instance collected on Saturday 12/17/2016, meaning that it will automatically be compared to the instance collected prior to it on Friday 12/16/2016.

2. Tracking New and Removed rows

  1. Select Last Two Instances mode
  2. The Track Changes option is now available for use
  3. You can now specify whether you want to see what fields have been added to the instance, the fields have been removed or both since prior period
  4. Id fields:
  5. Click Apply Changes to update the Results

Only those rows where the values defined in Id fields have been changed/added/removed since collecting the prior instance are shown.

Use case: If there are no rows in the Result set

In the example above, values from the calendar_date column are going to be new every day, since it includes values collected for a new day; values from units and sales are also highly likely to be different, unless the same amount of product units has been purchased or the sum of sales for current period is identical to the sum of sales for the prior period. The Dataset compares instances by values in channel and country columns:

New sales have been made in all countries and by all channels, but values in country and channel columns remained the same; e.g., Country = Australia, canada, France, Germany with Channel = corporate sales, store visit, website visit, email marketing), so the system has no changes to display in the Results set.

3. Defining additional filters

  1. Filters allow defining additional criteria to compare current and prior values by various conditions. NOTE: Current and prior filters are shown only in the Track Changes mode.
  2. If additional filters are applied to the results set, choose unchanged parameters (as in the example above) in the Id fields section. See the following example:

3.1. Simple Filter criteria

Use Case: Include rows if the sales in any country have increased by any amount over the prior day.

  1. By field: Select the field with constant (or unchanged) values. This field will serve as a basis for comparing other changed values. The Id fields are Channel and Country, analyzing changes when Channel and Country are unchanged
  2. Click [+ Rule].
  3. Define the parameters for comparing current and previous values from the drop-down lists.
  4. Apply changes to update the Results set

More rules can be added to the filters.

You may create a separate View out of this data slice by clicking Save as View at the top of the page.

3.2. Compound Filter criteria

Use Case: Include rows if units sold via 'website visit' channel have increased over the prior day OR if sales made via 'website visit' channel are 10% higher than over the prior day.

You want the key fields across which changes will be tracked included in the Select Field list.  In this example, you should select ONLY Channel, Country, units, and sales for inclusion in the display.

  1. By field: Select the field with constant (or unchanged) values. The Id fields should be Channel and Country (i.e. you are looking for changes when Channel and Country are unchanged)
  2. Define filters: Then you can apply filters. In our use case, this consists of 2 groups of conditions: click [+ Group] and define criteria for the first and second group:
    • [Group 1]: units increased in 'website visit' channel
    • [Group 2]: sales are 10% higher in 'website visit' channel
  3. Choose OR filter to define relations between the Groups
  4. Apply changes to update the Results

You may create a separate View out of this data slice by clicking Save as View at the top of the page.