Formatting data types for Performance Indicators
Who is this article for?Users who manage Performance Indicator settings.
PI_Admin(+ complex) or higher permissions are required.
As KPI data sources come in a range of data types and formats, the Performance Indicators (PIs) module allows you to format your data in several ways across data types. This guide will explain the standard formatting rules and give some working examples.
1. Setting a format
Formats are set for individual PIs from the item notebook.
They can only be set for the following data types:
- Duration
- Money
- Number
- Percentage
All custom formatting needs to follow the format mask, which is a string of symbols that tell the system how you want your data displayed. The following characters are used to build a mask:
| Character | Explanation |
|---|---|
| 0 | Placeholder for a numerical digit. Your data will have placeholder '0's prefixed if there are not enough digits in the value. |
| # | Placeholder for a numerical digit. Your data will not have placeholder '0's prefixed if there are not enough digits in the value. |
| . | Used to show the placement for a decimal point. |
| £ | Places a pound (£) sign. |
| % or '%' | Places a percentage (%) sign. |
| + or - | Places a plus (+) or minus (-) sign. |
| ' (single quote) |
This enables you to use a # or single quote symbol within your format, i.e. '#'##.00 applied to "123.4" will give you "#123.40". If you want to use a single quote in your format, for example with o'clock, you would need to put in two single quotes, i.e. "# o'clock" applied to "9" would give you "9 o'clock". |
| , (comma) |
This enables you to include a comma in your format. |
Browser
To format a PI:
- Open the PI notebook.
- Click 'PI Name▼'.
- Select 'Edit Settings'.
- Switch to the 'Advanced' tab.
- Enter your format mask in the 'Format' field (under 'Formatting').
Classic
To format a PI:
- Select the 'PI Central' topic button.
- Choose a PI from the list.
- Switch to the 'Settings' tab.
- Enter your format mask in the 'Format' field.
2. Default format
Leaving the format box empty will result in the default format being applied to the number.
All values are stored to a precision of up to five decimal places in the database.
| Data Type | Default Equivalent Mask | Explanation | Example Output |
|---|---|---|---|
| Percentage | #.##'%' | Maximum of two decimal places, percentage (%) sign suffix. | 1.23% |
| Number | #.### | Maximum of three decimal places. | 1.234 |
| Money | £#.00 | Pound (£) sign prefix, two decimal places. | £1.23 |
3. Format examples
Rounding to one decimal place for Percentage PIs
Percentage PI has a value of 33.33%. You want to display this to one decimal place only.
You would apply the mask '##.#'%'', so the value shown would be '33.3%'.
Showing commas in values over a thousand
Masks can include commas and formatting.
To create a format that inserts a comma for large values you'll need to use placeholder masks:
- '#,##0' applied to a value of 60000 will format as '60,000'
- '£#,##0' applied to a value of 5000 will format as '£5,000'