← Back to the hackathon home
Topic 11 of 18

DHIS2 Indicators

Step-by-Step Guide: Creating, Configuring and Testing Indicators

Purpose of this guide: This guide explains how to create an indicator in DHIS2 from the underlying data elements through testing and visualization. After each step, insert a screenshot from your own DHIS2 instance in the marked area.
Step 1: Understand What an Indicator Is

An indicator in DHIS2 is a calculated value derived from one or more data elements. Indicators are commonly used for rates, percentages, ratios and coverage measures.

INDICATOR
   │
   ├── Numerator
   │       ↓
   │   Data Element
   │
   ├── Denominator
   │       ↓
   │   Data Element
   │
   └── Factor
           ↓
        × 100

Example

Indicator: Malaria Testing Rate (%)

Numerator: Number of malaria tests performed
Denominator: Number of suspected malaria cases
Factor: 100
Expected result: You understand the numerator, denominator and factor required before creating the indicator.
The three parts of the indicator, with the numbers worked through.
Figure 1. The three parts of the indicator, with the numbers worked through. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Numerator. The confirmed cases, the top of the fraction.
  2. 2Denominator. The people tested, the bottom of the fraction.
  3. 3Factor. 100, which turns 0.682 into 68.2 per cent.
  4. 4150 confirmed. What the numerator adds up to in one facility and month.
  5. 5220 tested. What the denominator adds up to for the same facility and month.
  6. 668.2%. The answer DHIS2 should give. Keep this number to check with in Step 16.
Step 2: Check the Data Elements First

Before creating an indicator, confirm that the data elements needed for the calculation already exist.

Click: Maintenance / Metadata Management → Data Elements

For the malaria testing example, check for:

  • Malaria Suspected Cases
  • Malaria Tests Performed

If the required data element does not exist, create it before proceeding with the indicator.

Expected result: Both numerator and denominator data elements are available.
Your ten malaria data elements, found by searching your initials.
Figure 2. Your ten malaria data elements, found by searching your initials. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Data element. The side menu item you are in.
  2. 2Data element management. The list of everything that can be counted.
  3. 3Search. Your initials, so only your ten appear.
  4. 4Count. 1 to 10 of 10, which is what you created in Topic 1.
  5. 5The names. These are the names you will pick inside the expression builder.
  6. 6Value type. Integer, so the sums in the indicator work.
  7. 7Category combination. Sex of Child, so the indicator adds both columns together.
Step 3: Open Indicators

Open the Indicators section in the DHIS2 Maintenance/Metadata Management application.

Click: Maintenance app → INDICATOR tab → Indicator → list button

Search the list before creating anything. The demo already holds 77 indicators, and one of them may be close enough to copy.

Expected result: The Indicators list is displayed.
The INDICATOR tab, with the Indicator card and the Indicator type card.
Figure 3. The INDICATOR tab, with the Indicator card and the Indicator type card. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1INDICATOR tab. The orange line shows the tab you are on.
  2. 2Side menu. The same items as the cards, for quick jumping.
  3. 3Indicator. Where the indicator itself is created.
  4. 4Plus. Starts a new indicator.
  5. 5List. Shows the indicators that already exist. Always look here first.
  6. 6Indicator type. Where the factor lives, used in Step 4.
  7. 7Indicator group. For grouping indicators once you have several.
Step 4: Create an Indicator Type

Some DHIS2 versions use Indicator Types to define how an indicator is expressed, particularly the factor used for percentage or rate indicators.

Click: INDICATOR tab → Indicator type → list, and only use the blue plus if the type you need is missing
Example indicator type:

Name: Percentage
Factor: 100

For a percentage indicator, the factor is normally 100.

Expected result: A Percentage indicator type is available for selection when creating indicators.
The indicator types that already exist, with their factors.
Figure 4. The indicator types that already exist, with their factors. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Indicator type. The side menu item.
  2. 2Indicator type management. The list of types.
  3. 3Factor column. What each type multiplies by.
  4. 4Per cent, 100. Use this for positivity, coverage and completeness.
  5. 5Number, factor 1. Use this for a plain count, with a denominator of 1.
  6. 6Blue plus. Only use it when the factor you need is genuinely missing.
Step 5: Start Creating the Indicator

Return to Indicators and start a new indicator.

Click: INDICATOR tab → Indicator card → blue plus button

The indicator creation form should open.

Expected result: You see the fields needed to define the indicator.
The empty indicator form.
Figure 5. The empty indicator form. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1INDICATOR tab. The form opens on the same tab.
  2. 2Sharing note. The indicator will be public until you change it in Step 14.
  3. 3Name (*). Required.
  4. 4Short name (*). Required, and it must be unique.
  5. 5Code. Optional.
  6. 6Description. Optional, but write it anyway.
  7. 7Annualized. Off for a monthly rate.
  8. 8Decimals in data output. How many decimals people will see.
  9. 9Indicator type (*). Required. This is the factor, set in Step 7.
Step 6: Enter the Indicator Name

Give the indicator a clear and meaningful name.

Example:

Name: Malaria Testing Rate (%)
Short Name: Malaria Testing Rate
Code: MAL_TEST_RATE

Naming principle

The name should make it clear what is being measured and, where relevant, include the unit such as %, rate, ratio or coverage.

Name, short name, code and description filled in.
Figure 6. Name, short name, code and description filled in. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Name. Malaria Test Positivity Rate (%). The unit is in the name, so nobody has to guess.
  2. 2Short name. Malaria TPR, which is what charts and tables will show.
  3. 3Code. MAL_TPR, useful when another system asks for this indicator.
  4. 4Description. The formula in words: confirmed cases divided by people tested, times 100.
Step 7: Select the Indicator Type

Select the indicator type that corresponds to the calculation.

Select: Percentage

If you created a Percentage indicator type in Step 4, select it here.

Expected result: The indicator is configured as a percentage-type indicator.
The indicator type set to Per cent.
Figure 7. The indicator type set to Per cent. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Indicator type. Per cent, which carries the factor of 100.
  2. 2The arrow. Opens the list of types from Step 4.
  3. 3Annualized. Still off. Turning it on would multiply a monthly value up to a year.
Step 8: Build the Numerator

The numerator is the value that appears on top of the calculation.

Malaria Testing Rate:

Numerator = Number of malaria tests performed
Click: Edit numerator → search the data element → click its name → check the preview and the green Valid → DONE
Numerator
    =
Malaria Tests Performed
Expected result: The numerator expression contains the correct data element.
The numerator: two data elements added together.
Figure 8. The numerator: two data elements added together. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Description. Confirmed malaria cases, in words.
  2. 2The expression. Two data elements in curly brackets with a plus between them. Never typed by hand.
  3. 3Operators. Plus, minus, times, divide and brackets. Use plus to add the two test methods together.
  4. 4Tabs. Data elements is the one you need. Constants and reporting rates are also available.
  5. 5Search. Type RDT to shorten the list.
  6. 6The list. Click a name and it drops into the expression where the cursor is.
  7. 7Preview. The same expression with names instead of codes. Read this line, always.
  8. 8Valid. Green. If it says anything else, fix it before leaving.
  9. 9DONE. Keeps the numerator.
Step 9: Build the Denominator

The denominator is the value below the calculation line.

Malaria Testing Rate:

Denominator = Number of suspected malaria cases
Click: Edit denominator → build it the same way. For a plain count, type 1 as the whole expression
Denominator
    =
Malaria Suspected Cases
Expected result: The denominator expression contains the correct data element.
The denominator: the two testing data elements.
Figure 9. The denominator: the two testing data elements. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Description. People tested for malaria.
  2. 2The expression. RDT Tested plus Microscopy Tested, so every test counts once.
  3. 3Preview. Check that the two elements here are the tests, not the positives.
  4. 4Valid. Green again.
  5. 5DONE. Keeps the denominator. For a plain count, the whole expression would be 1.
Step 10: Set the Factor

The factor converts the ratio into the desired unit.

Indicator typeTypical factor
Proportion / percentage100
Rate per 1,0001,000
Rate per 10,00010,000
Rate per 100,000100,000
Example:
(Malaria Tests Performed ÷ Malaria Suspected Cases) × 100
The indicator type itself, where the factor of 100 lives.
Figure 10. The indicator type itself, where the factor of 100 lives. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Name. Per cent. Do not create a second type with the same meaning.
  2. 2Factor. 100. The indicator value is numerator divided by denominator, times this.
  3. 3Number. Ticked, because the result is a number rather than a yes or no.
  4. 4SAVE. Only needed if you had to create the type.
Step 11: Check How the Numbers Add Up

An indicator does not carry its own aggregation operator. It inherits the aggregation of the data elements inside it, which is why Topic 1 set every malaria data element to Sum.

Check instead: the two fields on the indicator form that do change the output, Annualized and Decimals in data output.
FieldWhat it doesFor this indicator
AnnualizedScales a monthly value to a yearOff
Decimals in data outputHow many decimals are shown1
Aggregation of the data elementsSet on each data element, in Topic 1Sum
Expected result: The indicator adds up correctly from facility to district to national, because the data elements underneath it do.
Annualized off and one decimal, the two fields that change the output.
Figure 11. Annualized off and one decimal, the two fields that change the output. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Annualized. Off. On would scale a monthly value to a year, which this rate must not be.
  2. 2Decimals. 1, so the dashboard shows 68.2 rather than 68.
  3. 3The name. Keep the per cent sign in the name, so the decimals make sense to readers.
Step 12: Review the Complete Indicator Formula

Before saving, review the complete calculation.

Malaria Testing Rate (%)

                    Malaria Tests Performed
                    ──────────────────────── × 100
                    Malaria Suspected Cases
Example:
Tests performed = 220
Suspected cases = 250

Indicator = (220 ÷ 250) × 100 = 88%
Expected result: The formula produces a meaningful value between 0 and 100% when the denominator is positive.
The whole indicator on one page, to read before saving.
Figure 12. The whole indicator on one page, to read before saving. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Name. What people will search for.
  2. 2Indicator type. Per cent, factor 100.
  3. 3Numerator. Both positive results added together.
  4. 4Denominator. Both test methods added together.
  5. 5Annualized. Off. Read the whole panel out loud before clicking save.
Step 13: Save the Indicator

Review the name, type, numerator, denominator, factor and aggregation settings.

Click: Save / Create
Expected result: The indicator appears in the Indicators list.
The saved indicator in the list, with the confirmation message.
Figure 13. The saved indicator in the list, with the confirmation message. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Search. Malaria, to find what you just made.
  2. 2Count. 1 to 1 of 1, so only your new indicator matches.
  3. 3The indicator. Malaria Test Positivity Rate (%).
  4. 4Indicator type. Per cent, exactly as you set it.
  5. 5The message. Indicator saved. If it does not appear, something was rejected.
  6. 6Blue plus. Use it again for the next indicator in Step 18.
Step 14: Configure Indicator Sharing

Make sure the appropriate users and user groups can access the indicator.

Open: Indicator → Sharing / Access

Configure access according to your implementation's governance requirements.

Expected result: Intended users can use the indicator in analytics applications where they have the required permissions.
Sharing settings for the indicator.
Figure 14. Sharing settings for the indicator. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Sharing settings. Opened from the row menu of the indicator.
  2. 2Add users and user groups. Type a group name to give it access.
  3. 3Public access. Everyone logged in. Leave view access unless there is a reason not to.
  4. 4What they can do. Metadata access decides who can change the formula.
  5. 5User groups. The programme team and the district clerks, each with their own level.
  6. 6APPLY. Saves the sharing settings.
Step 15: Test the Indicator in Data Visualizer

Open Data Visualizer and search for the indicator.

Click: Apps → Data Visualizer → Select the indicator

Select an organisation unit and reporting period with known underlying data.

Expected result: The indicator returns a calculated value rather than displaying an unexpected blank or error.
The indicator in the Data Visualizer, returning a number.
Figure 15. The indicator in the Data Visualizer, returning a number. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Data. Choose Indicators, then your indicator.
  2. 2Columns. Data, so the indicator runs across the top.
  3. 3Rows. Period, so the months run down the side.
  4. 4Filter. One organisation unit, here the country.
  5. 5The column heading. Malaria Test Positivity Rate (%).
  6. 6The values. Numbers, not blanks. A blank here means no data in that month.
Step 16: Compare the DHIS2 Result With a Manual Calculation

Always manually calculate at least one test value.

Example:

Malaria Tests Performed = 220
Malaria Suspected Cases = 250

Manual calculation:
220 ÷ 250 × 100 = 88%

Compare the manual result with the value returned by DHIS2.

Expected result: The DHIS2 result agrees with the manually calculated value, subject to the configured aggregation and data dimensions.
The numerator, the denominator and the indicator side by side.
Figure 16. The numerator, the denominator and the indicator side by side. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Confirmed cases. The numerator, added from the raw data elements.
  2. 2People tested. The denominator.
  3. 3The indicator. What DHIS2 worked out.
  4. 4One row. Take one month and read all three numbers across.
  5. 5The check. 150 ÷ 220 × 100 = 68.2, which matches. If yours is 0.68, the factor is wrong.
Step 17: Test Zero and Missing Denominators

Test what happens when the denominator is zero or missing.

Denominator = 0
Numerator = 0

Review the behavior in your DHIS2 version. A percentage cannot be meaningfully calculated when its denominator is zero.

Action: Confirm that your reporting and analytical interpretation handles zero/missing denominators correctly.
Facilities with no tests: the cell is empty, not zero.
Figure 17. Facilities with no tests: the cell is empty, not zero. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1A facility with data. Cases, tests and a rate, all present.
  2. 2A facility with zeros. Nobody was tested, so there is nothing to divide by.
  3. 3The empty cell. DHIS2 leaves it blank rather than showing 0%.
  4. 4Cases without tests. Twelve confirmed but nobody tested means the data is wrong, not the indicator.
  5. 5What to say. An empty cell is a missing denominator, and should be reported as such.
Step 18: Create Additional Malaria Indicators

Once the first indicator works, use the same process to create the remaining programme indicators.

IndicatorNumeratorDenominatorFactor
Malaria Testing Rate (%)Malaria tests performedSuspected malaria cases100
Test Positivity Rate (%)Confirmed malaria casesMalaria tests performed100
ACT Treatment Rate (%)Patients treated with ACTConfirmed uncomplicated cases100
Referral Rate (%)Malaria referralsMalaria cases100

Important: Confirm the programme's official indicator definitions before implementing these formulas. The examples above illustrate the structure, not a replacement for the NMCP indicator reference definitions.

The four malaria indicators once they are all created.
Figure 18. The four malaria indicators once they are all created. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Search. Malaria.
  2. 2Count. 1 to 4 of 4.
  3. 3ACT Treatment Rate (%). Treated with ACT over confirmed cases.
  4. 4Malaria Deaths. A plain count, with a denominator of 1.
  5. 5Test Positivity Rate (%). The one built in this guide.
  6. 6Indicator type. Number (Factor 1) for the count, Per cent for the rates.
Step 19: Final Indicator Quality Check
Final result: The indicator is configured, tested and ready for approved analytical use.
The details panel, used for the final check.
Figure 19. The details panel, used for the final check. This picture was drawn for the guide, using the indicator we are building. Your screen will show your own names and dates.
  1. 1Name. Reads correctly, with the unit.
  2. 2Indicator type. Per cent.
  3. 3Numerator. Both positives.
  4. 4Denominator. Both test methods.
  5. 5Annualized and decimals. Off and 1. Tick every line of the checklist against this panel.
Important distinction: An indicator is a calculated analytical object. It is not normally a replacement for the underlying data elements. Keep the underlying data elements well defined and use indicators to calculate the programme measures derived from them.