Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Calculate the Median from all above values in a chart

Hello,

i'm new to qlikview and have a problem to calculate the median.

Here ist my example

DAT1Value1Median1
01.01.201322
02.01.201353,5
03.01.201333
04.01.201374
05.01.201385
06.01.201314
07.01.201323
08.01.201384
09.01.201333
10.01.201323
11.01.201313

I thought it is something like : MEDIAN( {$<DAT1={"<=MAX(DAT1)"}>} Value1 )

But it doesn't work.

Best Regards,

Achim

3 Replies
nilesh_gangurde
Partner - Specialist
Partner - Specialist

Hiii arcsturm,

No need of witing the set expression for date if you are adding date as dimention.

you can do the following thing:

1. Take date as dimention.

2. Then Add "Median(Value1)" as  Expression.

For more clarification please see this:

median( [{set_expression}] [ total [<fld {,fld}>] ] expression )

Returns the aggregated median of expression iterated over the chart dimension(s).

This function has the same limitations for nested aggregation as the avg function. The median function supports sets and the total qualifier in the same way as the avgfunction.

Examples:

median( X )    

median( X*Y/3 )    

median( total X )    

median( total <Group> Price ) 

-Nilesh

Not applicable
Author

Hello Nilesh,

that doesn't work.

Here i have dat1 and value1 as an dimension, but median ( value1 ) is equal value1.

The median of 1.1.2013 is 2, from 2.1.2013 is 3.5, from 3.1.2013 is 3 .....

Greetings Achim

Not applicable
Author

here is the picture of the chart

Clipboarder.2013.05.10-005.png