IBM BPM, V8.0.1, All platforms > Authoring services in Integration Designer > Developing monitor models > What are monitor models? > Dimensional models
Dimensions
Dimensions are data categories used to organize and select monitoring context instances for reporting and analysis. Some examples of dimensions are time, accounts, products, and markets. Dimensions are composed of one or more hierarchical levels.
For example, a Location dimension can have City, Region, and Country levels.
In dimensional analysis, measures are what you add up (such as order quantity, cost of order), and dimensions are how you divide your data (such as time, customer, location, product). You might want to calculate average profit by city, or maximum salary by time.
A dimension consists of its dimension levels, and requires at least one level to be useful. The Location dimension levels of City, Region, and Country can be represented in the following dimension hierarchy:
- Country
- State
- City
Country is at a higher level than Region, which is at a higher level than City. If you consider a set of actual values that could fill this structure, you might have the following values at the Country level:
- Canada
- USA
At the Region level under Canada, you might have the following values:
- Ontario
- Quebec
- Manitoba
At the Region level under USA, you might have the following values:
- Michigan
- Wisconsin
- California
Each level enables you to aggregate the levels that are below it; for example, at the Country level, you might have the subtotal of all data for all regions. At the Region level, you might have the subtotal of all data for all cities.
The following table shows some examples of other dimensions and their possible dimension levels:
Dimension Dimension levels Location Country, Region, City Store Store country, Store region, Store city, Store ID Sales Representative Sales Representative ID Product Product Category, Product ID A dimension can consist of only one level, as illustrated by Sales Representative in the preceding table. The Sales Representative dimension would be useful if you wanted to look at the total or average number of orders by sales representative.
Dimension levels based on Date or DateTime metrics
If a dimension level has a source metric of Date or DateTime type, the dimension can have only one level. When the model is displayed, additional levels of Year, Month, and Day are automatically created in Cognos.
Dimension levels based on Duration metrics
If a dimension level is based on a duration metric, by default the values at each dimension level are the number of milliseconds that the duration metric represents, such as 600000, 600001, 600002, and so on. These values are typically far too granular to be useful, for example, for measuring the length of a customer interaction. If you want to use a duration as a dimension, it is better to have the dimension level based on a string metric. Add a metric value expression to the string metric that is triggered when the duration metric changes. The metric value expression maps the duration into one of a set of possible values based on the number of milliseconds.
For example, the string could display '0-1 days', '1-2 days', '2-3 days', and so on. In this example, a duration metric with a value of 600,000 milliseconds would be mapped to a string metric with the value of '0-1' days because it is in the range 0-86,400,000 milliseconds (there are 86,400,000 milliseconds in 24 hours).