Re: [Dhis2-users] [Dhis2-devs] Aggregating events based on last value of the data element

2017-04-10 Thread Markus Bekken
Dear Chathura and Pamod, Unfortunately, evaluating indicators using what would have been the latest value within every enrollment at a given time is not supported. We could make a program indicator that does the base calculation you want, but it will currently only reflect the disease

Re: [Dhis2-users] [Dhis2-devs] Aggregating events based on last value of the data element

2017-04-10 Thread chathura widanage
Hi Markus, Thanks for the response. Based on the scenario described above, we want to draw a trend chart which is similar to the one in attached png. So basically, given a date, api should consider the latest event(upto given date) of each entity when aggregating. Thanks On 10 Apr 2017 7:41

Re: [Dhis2-users] [Dhis2-devs] Aggregating events based on last value of the data element

2017-04-10 Thread Pamod Amarakoon
Forgot to add we also need to consider the fact that B gets positive for the disease again in May 2017 where we enroll him again and the total becomes *6* again. Thanx. On Mon, Apr 10, 2017 at 6:06 PM, Pamod Amarakoon wrote: > Dear Markus, > > If I elaborate more, suppose

Re: [Dhis2-users] [Dhis2-devs] Aggregating events based on last value of the data element

2017-04-10 Thread Pamod Amarakoon
Dear Markus, If I elaborate more, suppose there are 6 children A,B,C,D,E and F. A, B, and C are enrolled to the program in July 2016 being positive for the disease X (yes/no DE) D,E gets enrolled to programme in August 2016 also being positive for X F gets enrolled in September 2016 being

Re: [Dhis2-users] [Dhis2-devs] Aggregating events based on last value of the data element

2017-04-10 Thread Markus Bekken
Dear Pamod, to put it simply - if you use October 2016 as reporting date and display this enrollment program indicator, the pivot will be populated only with the data for the children enrolled in October 2016. The child enrolled in October will not show up un the numbers for November. If you

Re: [Dhis2-users] [Dhis2-devs] Aggregating events based on last value of the data element

2017-04-10 Thread Pamod Amarakoon
Dear Marcus, Want to clarify something. Suppose for example Child A has been marked positive for a disease in October 2016 and he has not turned up for further clinic followups. If we configure the program indicator the way you mentioned and select period dimension as last 12 months from pivot

Re: [Dhis2-users] [Dhis2-devs] Aggregating events based on last value of the data element

2017-04-10 Thread Markus Bekken
Hi there Chathura, it seems that the query you want to make below can be achieved with enrollment program indicators. Assuming the program is built as a multiple event with registration, and the DE1 is part of a repeating program stage, the inherent properties of enrollment program indicators