data_required: Input to model calculation. One row per required data pack...

data_requiredR Documentation

Input to model calculation. One row per required data pack column (from DATIM). Includes parameters (dimensions, items) for calling the indicators, and the key to dimension_items_sets for mapping to category options for output.

Description

Each data pack output can be the result of combining up to two DATIM indicators into a combining calculation. The indicators are designated A and B and the calculation combining them is in the calculation column.

Usage

data_required

Format

A data frame with these variables:

data_pack_sheet

Datapack Excel sheet label - from datapack schems

data_pack_code

given identifier to map output to a specific column in datapack - from datapack schema

type

numeric or percent - if percent then values recieved from DATIM will be divided by 100 - from datapack schema

full_formula

specification for required calculation/output - from datapack schema

allocate

determines how dimension that splits to multiple category options will be handled. If distribute the value returned by analytics will be multiplied by the weight from corresponding entry in dim_item_sets. Replicate means the value is copied and NA means there are no dimensions in the indicator call.

Note: when data are distributed it is sometimes the case that we receive results for a category option from more than one dimension (e.g. age 1-4 data can result from analytics dimension <5 and 1-9): These “duplicates” are added together in the code. This should not happen in the case of replicate and the program will throw an error if duplicate category options result from the indicator call.

A.dx_code

indicator code

A.dx_id

indicator uid

A.pe_iso

period (ISO/DHIS2 format) - currently only one supported

A.age_set

age set from dim_item_sets

A.sex_set

sex set from dim_item_sets

A.kp_set

key population set from dim_item_sets

A.add_dim_1

Name of additional dimension - details on one nonstandard (age, sex, kp) dimension used when calling the datim indicator. Currently on one dimension item is supported. These do not get mapped to category options as they act more as a filter than an explicit dimension.

A.add_dim_1_uid

additonal dimensions uid

A.add_dim_1_items

name of additional dimension item to filter on - only one supported

A.add_dim_1_items_uid

name of additional dimension item to filter on - only one supported

B.dx_code

see A.dx_code

B.dx_id

see A.dx_id

B.pe_iso

see A.pe_iso

B.age_set

see A.age_set

B.sex_set

see A.sex_set

B.kp_set

see A.kp_set

B.add_dim_1

see A.add_dim_1

B.add_dim_1_uid

see A.add_dim_1_uid

B.add_dim_1_items

see A.add_dim_1_items

B.add_dim_1_items_uid

see A.add_dim_1_items_uid

calculation

the formula for combiingthe A and B indicator values

Source

COP19 systems team


pepfar-datim/data-pack-commons documentation built on April 26, 2024, 12:09 a.m.