1

How to find weighted average using formulate to be able to use it in reports

Hi Team,

I am aware of several measure like sum, average being available.Can you share how i can calculate weighted average?

I have a usecase which has several such calculations and to migrate the flow to pyramid i want to be able to do that.

2 replies

null
    • Let me connect you
    • Community_chris
    • 2 mths ago
    • Reported - view
    • Customer Solutions Architect
    • Moshe_Yossef
    • 2 mths ago
    • Official response
    • Reported - view

    Hi 

    Weighted average is by definition Sum(weight * measure) / Sum(Weight).

    So I would follow these steps:

    1. create a calculated column (in the model or in formulate, the model looks more appropriate in this case as it is quite generic)  that will be (weight column) * (measure column).

    2. Define a measure for this column that will use sum aggregation.

    3. make sure you also have a measure with a Sum aggregation for the weight column.

    4. create a formula (in formulate), that will divide the measure from 2 with the measure from 3.

     

    That should work.

    Moshe

Content aside

  • Status Answered
  • 1 Likes
  • 2 mths agoLast active
  • 2Replies
  • 56Views
  • 3 Following