# Quality of outpatient and inpatient data

Whether the OPD and IPD data are complete, free of extreme outliers and consistent enough to interpret, year by year.

Before outpatient visits and admissions are interpreted, their data are checked like any other facility data: are the
monthly reports complete, are there *missing values* (A month with no number reported for an indicator in a district. Measured by the share of districts with no missing monthly values, and replaced in data adjustment by the district's median monthly value for the year.) or *extreme outliers* (A monthly value more than 5 times the median absolute deviation (MAD) from the median monthly value of the same series (district, or the national or admin-1 series being assessed), the median and MAD being computed from all years except the most recent one (source). In data adjustment it is replaced by the median of the district's non-outlier months in the same year.), and are the
numbers for children under 5 consistent with those for all ages? The checks are those of the
[Data quality assessment](https://datasuite.damurka.com/en/methodology/data-quality.md), applied to the *OPD* (Outpatient department: visits to a facility that do not need an overnight stay.) and *IPD* (Inpatient department: admissions of patients who stay at least one night in a hospital or a facility with beds. Admissions include new admissions and re-admissions.) data, and gathered in
one table.

> **Note**
>
> **At a glance**
> - **Measures:** completeness of reporting, missing values and extreme outliers in the OPD and IPD data, and three consistency checks.
> - **Good result:** reporting and data quality indicators of 90% or more every year, under-5 shares within their usual range.
> - **In the app:** the *Data Quality Metrics* table of **[Service Utilization DQA](https://datasuite.damurka.com/en/apps/countdown/service-utilization-health-system/service-utilization-dqa.md)**.

## Why

As with maternal care, newborn care and immunization, data quality is systematically assessed first. Adjustments are then
applied to correct for incomplete reporting, and extreme outliers are resolved, in
[Data adjustment](https://datasuite.damurka.com/en/methodology/data-adjustment.md). This adjusted, clean dataset is then used for the trends and
comparisons at national and sub-national level.

Reporting rates from hospitals and facilities with inpatient departments can be more complex to track than routine
outpatient data, and extreme monthly outliers are common in inpatient data because of compilation errors: a year can look
like a change in use when it is a change in reporting.

## What

| Indicator | Numerator | Denominator | Interpretation |
| --- | --- | --- | --- |
| % of expected monthly facility reports (national) | Number of monthly OPD reports received | Number of monthly OPD reports expected | Reporting rates over 90% are good |
| % of districts with reporting rates ≥ 90% | Number of districts with at least 90% reporting completeness in the year | Total number of districts | Identifies districts with low reporting |
| % of non-missing OPD (IPD) monthly values | Number of monthly under-5 OPD (IPD) values that are not missing | Total number of monthly values expected | Shows how much of the year is missing |
| % of districts with no missing OPD (IPD) values | Number of districts with no missing under-5 OPD (IPD) value in the year | Total number of districts | Shows whether missing values are spread or concentrated |
| % of OPD monthly values that are not extreme outliers | Number of monthly under-5 OPD values that are not extreme outliers | Total number of monthly values | At least 99% expected; consider reasons |
| % of districts with no OPD extreme outliers | Number of districts with no extreme outlier in under-5 OPD in the year | Total number of districts | At least 90% expected; consider reasons |
| Ratio of OPD to IPD, under 5 | Number of under-5 OPD visits | Number of under-5 admissions | Usually between 16 and 47 |
| % of OPD visits that are children under 5 | Number of under-5 OPD visits | Number of OPD visits, all ages | Usually 15% to 45% (see [Outpatient service utilization](https://datasuite.damurka.com/en/methodology/service-utilisation/outpatient.md#what)) |
| % of admissions that are children under 5 | Number of under-5 admissions | Number of admissions, all ages | Usually 10% to 40% (see [Inpatient service utilization](https://datasuite.damurka.com/en/methodology/service-utilisation/inpatient.md#what)) |

How each check is computed (reporting rate, missing values, the extreme outlier rule) is explained in
[Completeness of monthly facility reporting](https://datasuite.damurka.com/en/methodology/data-quality/reporting-completeness.md),
[Missing monthly values](https://datasuite.damurka.com/en/methodology/data-quality/missing-data.md) and
[Extreme outliers](https://datasuite.damurka.com/en/methodology/data-quality/outliers.md).

## Settings

| Setting | Default | What it means |
| --- | --- | --- |
| District threshold | 90% | A district reports well when its reporting rate is at least this. It is set on the **Reporting Rate** page of the data quality assessment. |
| Extreme outlier bound | 5 × MAD | A monthly value is an extreme outlier when it is more than 5 median absolute deviations from the district's median. |

## Interpretation

- **Are reporting and the other data quality indicators at 90% or more every year?** If not, note the years and treat their utilization rates with caution.
- **Are IPD values missing in some districts or years?** Missing admissions lower the admission rates and raise the ratio of OPD to IPD; check them before reading the [inpatient](https://datasuite.damurka.com/en/methodology/service-utilisation/inpatient.md) results.
- **Is the ratio of OPD to IPD for children under 5 between 16 and 47?** A much higher ratio means few admissions for the number of visits: under-reported admissions, or missing inpatient reports.
- **Are the under-5 shares of OPD visits and of admissions in their usual range, and stable between years?** A change of more than 5 percentage points between years flags a data quality problem.

### Example: the data quality table, national

![Service utilization data quality table by year: reporting, missing values, extreme outliers and consistency checks](https://datasuite.damurka.com/images/service-utilisation-out-dqa.png)

**Reading the chart:** one column per year. Rows 1a to 1f are completeness of reporting and missing values, 2a and 2b
extreme outliers, 3a to 3c the consistency checks (3a the ratio of OPD to IPD for children under 5, 3b and 3c the under-5
shares of OPD visits and admissions). Cells are green at 90% or more, yellow from 70% to 90% and red below 70%. The
footnote gives the reference ranges of the consistency checks as the table shows them.

**What it shows:** reporting is complete (94% to 100% of expected reports), except that only **76%** of districts reached
the 90% threshold in the first year. OPD values are never missing and almost never extreme outliers. IPD values are
complete until the last year, when **3%** are missing and only **85%** of districts have no missing IPD value. The
consistency checks show the real problem: the ratio of OPD to IPD for children under 5 is **137** and **609** in the first
two years, far above 16 to 47, and only **12%** and **3%** of admissions are children under 5. Under-5 admissions are
under-reported in those two years, so their inpatient rates cannot be compared with later years. The under-5 share of
OPD visits is stable at **28% to 31%**.

## After the assessment

The OPD and IPD data are adjusted for incomplete reporting and extreme outliers in
[Data adjustment](https://datasuite.damurka.com/en/methodology/data-adjustment.md), like the other indicators. For inpatient data, whether to adjust for
incomplete reporting is the country team's judgement (see
[Inpatient service utilization](https://datasuite.damurka.com/en/methodology/service-utilisation/inpatient.md#why)). Years with a weak table are read
with caution in the [outpatient](https://datasuite.damurka.com/en/methodology/service-utilisation/outpatient.md) and
[inpatient](https://datasuite.damurka.com/en/methodology/service-utilisation/inpatient.md) analyses.
