Custom Analysis guide

Introduction

Core Journey performs analyses of event data. An analysis may apply to past, present, or future events. Custom Analysis are performed conditionally based on custom, user-defined specifications. An analysis consists of runtime processes that compute a result and a database relation that persists that result. Once persisted, analysis results may then be queried for inspection and reporting.

Custom Analysis Schema

A custom analysis persist results in a database relation whose schema is determined by the user-defined analysis specification.

The name of the relation is derived from the name of the analysis, replacing special characters, like spaces, with underscore, converting to lower case, and appending the prefix otec_user_ (a namespace used to designate OpenText user relations.) For example, an analysis named Users by Country produces a schema named otec_user_users_by_country.

The fields (columns) of the relation correlate to the fields of the analysis, using the user-defined name, typed according to the input event schema and any applied function. For example, a text field named country creates a text column with the same name. Whereas a date field named circa with year function would create a numeric column named circa (containing the date's year.)

Additionally, note that all analysis models (optionally advanced) are designed to apply to one or more aggregations produced by a journey and stage. Accordingly, their schema automatically includes primary key fields, journey_id and stage_id, to identify the source aggregation and to support query join with journey/dataset metadata. These fields precede user-defined fields in the generated primary key.

Custom Analysis Models

Journey supports custom, user-defined analyses based on the following analysis models:

  • Event Classification Analysis (List)
  • Event Distribution Analysis (Drill Down)
  • Value Detail Analysis
  • Advance Analysis

Event Classification Analysis (List)

Event Classification, referred to as List in the Customer Journey User Interface, is used to specify a classification of events according to one or more ordered classification fields. The classification fields comprise a unique (primary key) combination to be classified. An example would be "which users visited which websites" where the classification fields would be site and user identifiers. Combined with the automatic journey and stage fields, a hypothetical "Sites and Users" analysis schema might then be:

Schema: otec_user_sites_and_users

Field Name Field Type Description
journey_id text Journey (data set) id
stage_id text Stage (data point) id
site_url text Site identifier
user_id text User identifier

Event Classification Analysis (Drill Down)

Event Distribution, referred to as Drill Down in the User Interface, is used to specify a count of events, optionally distributed over one or more ordered, dimensional fields. The dimensional fields comprise the unique (primary key) combination to be counted. A counter field named events_count is automatically created. An example would be "how many events occurred by country, region and city". A hypothetical "events by location" schema might then be:

Schema: otec_user_events_by_location

Field Name Field Type Description
journey_id text Journey (data set) id
stage_id text Stage (data point) id
country text Country name
region text Region name
city text City name
events_count counter Count of events

Value Details Analysis

Value Details is used to track ancillary, mutable metadata (details) for a uniquely identified reference value. The unique identifier for the value comprises the primary key, and the detail(s) comprise non-primary columns containing the last observed value for each. A primary example is the system Detaset Metadata analysis, where the keys are journey_id and stage_id, and mutable details include names, order and labels. A hypothetical custom example would be ecommerce "product details" where the key might be a project sku, and mutable details include description, cost and inventory:

Schema: otec_user_product_details

Field Name Field Type Description
sku text Product sku
description text Product description
cost decimal Product cost
inventory int Product inventory

Advanced Analysis

Advanced analysis does not prescribe a predefined model, rather it allows more arbitrary specification using JavaScript Object Notation (JSON), as described in the User Interface. An advanced analysis is typically written by someone in a technical role working with OpenText Professional Services.