Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
simona_un
Contributor
Contributor

Weighted average (sumproduct)

Hi,

I have this challenge where I would like to calculate the weighted average of person by exposure across the year and package:

simona_un_0-1719578223305.png

Any idea how to solved it?

 

Thanks 🙂

Labels (1)
1 Reply
marksouzacosta
Partner - Specialist II
Partner - Specialist II

Hi @simona_un,

I believe the correct Excel expression is this one right?
SUMPRODUCT(D3:D12,C3:C12)/SUM(D3:D12)

If so, this is how you can do in Qlik:

How I have loaded your data:

LOAD
[Policy],
[Count of person],
[Exposure],
[Package],
[Year]
FROM
[lib://DataFiles/Weighted average.xlsx]
(ooxml, embedded labels, table is Sheet1)
;

And the expression on a KPI chart:

=Sum([Exposure] * [Count of person])/Sum([Exposure])

marksouzacosta_0-1719610473809.png

Is this what are you looking for?

Regards

Mark Costa

Read more at Data Voyagers - datavoyagers.net