Data models ● Aggregate data: ○ Routinely collected ○ Mostly numbers ● Events:(Indoor Hospital) ○ Occurs at any time ○ Describes an event that took place ● Tracking data: (EPI Cold Chain, Kala-Azar, MCH Tracker, HIV-AIDS, Cervical Breast Cancer Tracking) ○ Data linked to an identifiable entity ○ Data can be linked to stages in program
A data value in DHIS2 is described by at least three dimensions: 1) data element, 2) organisation unit, and 3) period. These dimensions form the core building blocks of the data model.
Fixed Data Dimension:
Example:
Dynamic Data Dimension:
Example:
Dynamic Data Dimension: Organization Unit group sets
Dynamic Data Dimension: Organization Unit group sets example
Dynamic Data Dimension: Category options group sets
Dynamic Data Dimension: Category options group sets example
Data Dimensions - Events: ● Fixed dimensions ○ Program ○ Periods ○ Organisation units Example:● Dynamic dimensions ○ Data elements ○ Attributes
● Source for aggregate data - used by all DHIS 2 analysis apps ● Useful for integration with third-party tools ○ Analysis tools like R, Stata, SPSS ○ Integration with external systems/tools like SSI ● Exposed as REST Web API and Java API ● Analytics tables must be generated (ad-hoc or scheduled) ● Pivot table & event reports can be used as API browser
● Dimensions are uniform ○ No need to know the underlying object type ● Get all dimensions from API ○ /api/dimensions Example:http://103.247.238.86:8081/dhis28/api/dimensions Result: { "pager": { "page": 1, "pageCount": 1, "total": 1, "pageSize": 50 }, "dimensions": [ { "id": "mc2ceK4TjB6", "displayName": "Sex" } ] }● URL syntax ○ /api/analytics?dimension=dim-id:item-id;item-id;
● Returns data values aggregated across dimensions ○ /api/analytics ● dimension query parameter ○ Defines which dimensions to include in response ● filter query parameter ○ Defines which dimensions to apply as filter for response
● Expression with data elements ● Indicator type ● Numerator and denominator
● Expression and Filter ● Aggregation types ● Functions ● Variables
● Apply filters to data in the response Operators: EQ, GT, GE, LT, LE ● Format: measureCriteria=criteria:value;criteria:value ● Example: api/analytics?measureCriteria=GE:6500;LT:33000
Data models ● Aggregate data: ○ Routinely collected ○ Mostly numbers ● Events:(Indoor Hospital) ○ Occurs at any time ○ Describes an event that took place ● Tracking data: (EPI Cold Chain, Kala-Azar, MCH Tracker, HIV-AIDS, Cervical Breast Cancer Tracking) ○ Data linked to an identifiable entity ○ Data can be linked to stages in program
A data value in DHIS2 is described by at least three dimensions: 1) data element, 2) organisation unit, and 3) period. These dimensions form the core building blocks of the data model.
Fixed Data Dimension:
Example:
Dynamic Data Dimension:
Example:
Dynamic Data Dimension: Organization Unit group sets
Dynamic Data Dimension: Organization Unit group sets example
Dynamic Data Dimension: Category options group sets
Dynamic Data Dimension: Category options group sets example
Data Dimensions - Events: ● Fixed dimensions ○ Program ○ Periods ○ Organisation units Example:● Dynamic dimensions ○ Data elements ○ Attributes
● Source for aggregate data - used by all DHIS 2 analysis apps ● Useful for integration with third-party tools ○ Analysis tools like R, Stata, SPSS ○ Integration with external systems/tools like SSI ● Exposed as REST Web API and Java API ● Analytics tables must be generated (ad-hoc or scheduled) ● Pivot table & event reports can be used as API browser
● Dimensions are uniform ○ No need to know the underlying object type ● Get all dimensions from API ○ /api/dimensions Example:http://103.247.238.86:8081/dhis28/api/dimensions Result: { "pager": { "page": 1, "pageCount": 1, "total": 1, "pageSize": 50 }, "dimensions": [ { "id": "mc2ceK4TjB6", "displayName": "Sex" } ] }● URL syntax ○ /api/analytics?dimension=dim-id:item-id;item-id;
● Returns data values aggregated across dimensions ○ /api/analytics ● dimension query parameter ○ Defines which dimensions to include in response ● filter query parameter ○ Defines which dimensions to apply as filter for response
● Expression with data elements ● Indicator type ● Numerator and denominator
● Expression and Filter ● Aggregation types ● Functions ● Variables
● Apply filters to data in the response Operators: EQ, GT, GE, LT, LE ● Format: measureCriteria=criteria:value;criteria:value ● Example: api/analytics?measureCriteria=GE:6500;LT:33000