Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

Correctly Weighting Average Handle Time (AHT) KPI in DAX

Hello Team,

 

I work in a call center where we have a set of KPIs, one of which is Average Handle Time (AHT) with a target of 600 seconds or less. For this metric, a lower AHT is better; for example, an agent with an AHT of 300 seconds is considered better than an agent with 600 seconds.

I need to assign a weight of 10% to this metric within the total KPIs, where agents who achieve an AHT of less than 600 seconds receive the full weight. I don't know how to create that can assume a higher AHT is not better when it should be the opposite.

 

Thanks,

  • Anonymous's avatar
    Anonymous
    2 years ago

    Thank you for your prompt reply Greg_Deckler 

     

    Hi Anonymous 

    Based on your needs ,I have created the following table:

     

     

    You can create the following formula to classify AHT, assuming <=600 is marked as "good" and >600 is marked as "bad"

    Measure = IF(SELECTEDVALUE('Table'[AHT])<=600,"good","bad")

     

    You can use the following DAX to calculate the percentage of time less than or equal to 600 seconds

    KPI = DIVIDE(CALCULATE(COUNTROWS('Table'),FILTER('Table',[Measure]="good")),COUNTROWS('Table'))

     

    Result:

     

     

     

     

     

     

     

     

    Best Regards,

    Jayleny

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

4 Replies

  • Greg_Deckler's avatar
    Greg_Deckler
    Icon for Community Champion rankCommunity Champion

    Anonymous Seems like a simple IF statement but Sorry, having trouble following, can you post sample data as text and expected output?
    Not really enough information to go on, please first check if your issue is a common issue listed here: https://community.powerbi.com/t5/Community-Blog/Before-You-Post-Read-This/ba-p/1116882

    Also, please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

    The most important parts are:
    1. Sample data as text, use the table tool in the editing bar
    2. Expected output from sample data
    3. Explanation in words of how to get from 1. to 2.

  • Anonymous's avatar
    Anonymous
    Not applicable

    Thank you for your prompt reply Greg_Deckler 

     

    Hi Anonymous 

    Based on your needs ,I have created the following table:

     

     

    You can create the following formula to classify AHT, assuming <=600 is marked as "good" and >600 is marked as "bad"

    Measure = IF(SELECTEDVALUE('Table'[AHT])<=600,"good","bad")

     

    You can use the following DAX to calculate the percentage of time less than or equal to 600 seconds

    KPI = DIVIDE(CALCULATE(COUNTROWS('Table'),FILTER('Table',[Measure]="good")),COUNTROWS('Table'))

     

    Result:

     

     

     

     

     

     

     

     

    Best Regards,

    Jayleny

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thanks, Anonymous for your reply. It works however my issue is that I need to have something like

      Score Measure= IF(Table [AHT]<= 600, AHT Score* Weight (20%)). Based on this formula the system gives the employee who scored high AHT the highest score however in a metric like AHT the agent who hit high AHT shouldn't get the highest score since he is an outlier. 

      Hope this is clear now

    • priya1234's avatar
      priya1234
      New Member

      Hi Anonymous , have you found any solution for it?