How do I work out the median?
-
- Posts: 0
- Joined: Wed Feb 21, 2018 4:52 pm
How do I work out the median?
I_m writing a report in Report Writer to get various appeal analysis details _ no of responses, average donation etc., which is all fine. However one of the requirements is the median amount of the appeal. I can work out easily what the median number is _ i.e. if we have 40 responses the median number is 20. What I can_t work out and don_t know if it_s possible in Report Writer, is how do I then find out what the amount is that the 20th record in the output gave to the appeal (assuming the report records are sorted on AMOUNT ascending).
-
- Posts: 0
- Joined: Wed Feb 21, 2018 4:52 pm
==> How do I work out the median?
Thank you very much Kathleen - I^ll give it a go.
=> RE: How do I work out the median?
Create two total fields that count response and reset when the appeal changes. Make the second one pre-processed.____The create a calculated field with the expression:____IIF(running=round(count/2,0),amount,0)____where running is the running total and count is the pre-processed total.____Finally create a total that sums the calculated field, accumulates for each record and resets by appeal.____I think this should get you there.____Kathleen__R&R Support
-
- Posts: 0
- Joined: Wed Feb 21, 2018 4:52 pm
===> RE: How do I work out the median?
Works a treat - thank you Kathleen