IBM BPM, V8.0.1, All platforms > Authoring services in Integration Designer > Developing monitor models > Create monitor models > Defining KPI models

Defining key performance indicators (KPIs)

Key performance indicators (KPIs) are quantifiable measurements of the improvement or deterioration in the performance of an activity critical to the success of a business. A KPI can have a target, a set of ranges, or both, which measure how well a business is achieving its objectives. A KPI obtains its value either from aggregating a metric or from a calculation based on other KPIs or user-defined XML Path Language (XPath) functions.

Before defining a KPI, you must have defined a KPI context.

To define a KPI:


Procedure

  1. Click the KPI Model tab of the editor, right-click the KPI context (or any element of the KPI context) in the model tree, and click New > KPI. Alternatively, click New > KPI From Library. See "Adding KPIs from the KPI library" for more details.

  2. In the Create New KPI window, type a name in the Name field and click OK. The name is limited to 256 characters. As you type the name, a default ID is created for you, although you can change it if you prefer. The ID is required, and must be unique in the monitor model. The ID must be an XML NCName (non-colonized name), which means that it must start with a letter or underscore, and can only contain letters, digits, underscores, hyphens, and periods.

    You might find the following naming scheme useful when naming KPIs:

    • Operator name (such as maximum or average)
    • Metric name

    • Optionally, metric data type and whether the value is based on a duration.
    • Time reference (such as year or month)

    as in the following examples of KPI names:

    • Total Orders [Y]
    • Max Completed Orders
    • Max Orders $/Day [M]
    • Max Orders $/Day [Y]

    Although the name of the KPI should be meaningful, try to keep it short for viewing at run time.

    The KPI is added to the model tree under the KPI context, and the form editor opens so that you can define the KPI context.

  3. Specify the type of the KPI, either Decimal or Duration. For a decimal KPI, select formatting options that control how the KPI values are displayed at run time.

    1. To format the KPI as a currency value, select the type of currency. The other options are disabled.

    2. Select the number of decimal places to include in the KPI value.

    3. Select Show as a percentage to format the KPI value as a percentage. At run time, the value will be multiplied by 100 and a percent sign (%) will be added.

      For example, 0.3 becomes 30%.

  4. To preserve the historical values of KPIs for viewing and analysis, select Keep track of historical values for this KPI. KPI values will be calculated hourly and kept in a KPI history table. In the KPI Manager widget, you will be able to create prediction models and use the collected historical data to predict future trends for the KPI.

  5. Optional: Specify the initial target, ranges, or both as follows:

    1. To add a target, click Details to specify the display name, ID, description, and value. The KPI target is added to the model tree under the KPI.

    2. To add ranges, select whether you want to specify each range as a percentage of the target value (that is, the target is treated as 100%) or as an actual value. Click Add to add a range and specify the name and description in the Add Range window. The description is used only in the Monitor Model editor and is not displayed anywhere in Business Monitor. In the table, click the Start Value and End Value cells and specify the values. Both values are required. The start element of each row must equal the end element for the previous row.

      If you add your start and end range values before creating the next range, then, when you click Add, the start value of the new range will be automatically configured with the end value of the previous range.

    3. To select the color to be used for display at run time, click the Color cell and click the button that appears. You can specify a color for each range.

    The ranges are added to the model tree under the KPI. After adding ranges, you can click Sort to sort them from the lowest start value to the highest start value.

    You can also click a column heading to sort the values by that column. Click the column heading a second time to reverse the sort order.

  6. Select whether this KPI is based on a metric and aggregation function or on a calculation based on other KPIs or user-defined XPath functions. In Business Space, these KPIs are called Aggregate KPIs and Expression KPIs.

  7. If the KPI is based on other KPIs or XPath functions, write an expression to calculate the value of the KPI. For content assist, press Ctrl+Space. You can use XPath functions to retrieve KPI values from sources outside Business Monitor.

  8. If the KPI is based on a metric and aggregation function, specify the details of the KPI as follows:

    1. Click Browse and select the monitoring context in which the metric (or key, counter, or stopwatch) is found. Click Browse and select the metric, or click New to create a new metric.

      When possible, use duration metrics instead of stopwatches as the source of KPIs. KPIs based on stopwatches will not perform as well as KPIs based on duration metrics, because actively running stopwatch values are calculated in the database for each instance to be aggregated. Basing a KPI on a stopwatch also limits your options for tuning the database in the future.

    2. Select the aggregation function to apply to the metric. If the aggregation function is not appropriate for the type of the metric, you will see a validation error. See "Aggregation functions" for more information.

    3. Select whether the KPI calculation should use values collected from all versions of the model, including all previous and future versions, or use only the values from the currently selected version of the model. In general, if the semantics of the KPI have not changed, include all versions. However, if a new version of the KPI has incompatible changes, choose only the current version.

    4. To select a time period over which the KPI should be evaluated, click Browse and select a metric from the same monitoring context as the metric used to calculate the KPI. The metric must have a type of Date or DateTime.

      • To calculate the KPI based on data from a repeating time period, click Repeating and select daily, monthly, quarterly, or yearly. Select whether you want to evaluate data for the last full period or for the period in progress.

        For example, if you select a daily time period, then the KPI can either be based on the values up to yesterday, or be based on the values that include the day so far. Select the time zone. The default value is your current time zone in the Monitor Model editor. If you want daylight saving time to be taken into account at run time, select a location.

      • To calculate the KPI over a window of time that moves continuously, click Rolling. Select minutes, hours, days, months, or years and enter the number that you want, for example, 10 minutes or 90 days. If you select 90 days, for example, the value of the KPI will be based on the last 90 days up to the current time (not from midnight to midnight).

        For example, if it is currently October 17th, 2007 12:30 PM and you select 3 months, the KPI will be based on all instances from July 17th, 2007 12:30 PM to October 17th, 2007 12:30 PM. In Business Space, this kind of time interval is called Sliding.

      • To calculate the KPI over a single time period, click Fixed and select the start date and the end date. If you specify a start date only, the KPI is calculated beginning at that date and continuing to the current date. If you specify an end date only, If you specify an end date only, the KPI is calculated using all data up until the end date. Select the time zone. The default value is your current time zone in the Monitor Model editor. If you want daylight saving time to be taken into account at run time, select a location.

    5. Select any data filters that apply to the KPI.

      For example, you might have a KPI called Average Order Amount for Longtime Customers, so you are only interested in the Order Amount metric in monitoring contexts in which the Customer Years metric contains a number greater than 5. Click Add and select the metric, key, counter, or stopwatch to use as a filter, or click New to create a new one. The filter is added to the table.

      • In the Operator cell, click the operator to apply. Based on the data type, the following comparison operators are available:

        String Integer, Decimal (includes counters) Boolean Duration (includes stopwatches) Time
        = = = = =
        != != != != !=
        < < IS NULL < <
        > > IS NOT NULL > >
        <= <=   <= <=
        >= >= >= >=
        IN IN IS NULL IN
        NOT IN NOT IN IS NOT NULL NOT IN
        IS NULL IS NULL   IS NULL
        IS NOT NULL IS NOT NULL IS NOT NULL
        LIKE (% and _ wildcards)    
        NOT LIKE (% and _ wildcards)

      • Click the Value cell and click the button that appears. Depending on the operator selected, the value might be a list of values. In this case, a list window is displayed in which you can quickly add and edit values. Otherwise, you can type the values directly, or type an XPath expression that specifies the values to use in the filter condition.

        If the value is a list of values, each value must be surrounded by single quotation marks and the values must be separated by commas.

      • If the metric type is String, the Case-sensitive column is enabled and you can select the check box to indicate that any comparisons should be case-sensitive. Unless you are certain about the case of the incoming value, leave the box cleared.

        For example, you might not know in advance whether a City value will be London or LONDON.

      • Nulls are allowed in metrics used in KPI data filters.

        For example, if you have a KPI named Average Order Amount for London Customers and the city metric is null, the aggregation will continue with just the instances that have the city metric set to London.

      • When the operator is like or not like, you can use wildcards. Use % (the percent sign) to match zero or more characters, and _ (underscore) to match exactly one character.

        For example, if the operator is like and you enter %customer%, any text with the word customer anywhere in it is a match. If you enter customer_, only text with the word customer at the beginning followed by a single character, for example customer1, is a match.

      • If you create more than one data filter, the data filters are logically combined with the AND operator.

        For example, if you specify two data filters, metric1 = 'x', metric2 = 'y', the data will be aggregated for all instances where metric1 = 'x' and metric2 = 'y'. The OR operator is not available, but if you want to match one value or a different value for the same metric, you can use the IN operator.

        For example, if you want to aggregate the data for instances where metric1 = 'x' or metric1 = 'y', you can specify the following data filter: metric1 IN 'x','y'.

Defining KPI models