I am creating a DE with about 5 COCs. The DE is to calculate inventory. We will need to add and subtract one COC or the other.
Say for instance, the indicator may be calculated as:
(COC1 + COC2) - (COC4) / (COC3 + COC5).
For the DE is it better if I use NONE or CUSTOM as the aggregationType?
I am asking because after I created the metadata and generate data. I figure out that I the indicator is not appearing in the visualizer app. It says both that NONE and CUSTOM aggregationType cannot be used for disaggregation.
Does it mean I cannot use COC for the scenario above?
When using DHIS2 for inventory tracking, it is common practice to have a DE for a type of commodity, and COCs for various measures of the commodity. COCs can be used for such things as:
Stock level at the beginning of a period
Amount restocked during the period
Amount used during the period
Amount wasted/lost/expired/stolen during the period
If this is the kind of thing you’re trying to do, then you’re on the right track.
Note that if you capture the data at a lower level of organisation unit than the one you report at with an indicator, then the data will have to be aggregated. For example, are you trying to show the percentage of something at a district level where the data is collected at the facility level? Then the data element should have some kind of aggregation function, such as SUM.
If you could be more descriptive about what you want the indicator to show, I might be able to better advise you.
Initially I was using data element for all the measures of the commodity. But after switching to COC, and refactoring the indicator calculation as I explain above it is now working.