Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
alurubs
Contributor
Contributor

Comparing two measures from same column

I am trying to create a very simple bar graph with the below data.

EmployeeTime booked
A3
A2
A5
B8
B2
C4
C6
C7
C9
D1
D4
D8
D2
E6

 

In the bar graph what I need is a comparison of the average time booked by employee A versus the average time booked by all five employees. The graph should show the first bar for employee A with 3.33 value and the second bar for all five employees with value 4.78

What do I need in dimensions and how can I get two Measures from the same Time booked column, first measure being average for employee A only and second measure being  the average for all employees?

Thanks

Bala

1 Solution

Accepted Solutions
Lisa_P
Employee
Employee

Just create a bar chart with 2 measures:

Measure 1:

Avg({<Employee={A}>}[Time booked])

Measure 2:

Depends on if you want all bookings averaged, or averaged by employee.

avg(aggr(Avg([Time booked]), Employee))

or 

Avg([Time booked])

 

View solution in original post

2 Replies
Lisa_P
Employee
Employee

Just create a bar chart with 2 measures:

Measure 1:

Avg({<Employee={A}>}[Time booked])

Measure 2:

Depends on if you want all bookings averaged, or averaged by employee.

avg(aggr(Avg([Time booked]), Employee))

or 

Avg([Time booked])

 

avinashelite

you need just the A to be compared with all the average or you want to memic this with other values also ?