Forum Discussion

bdehning's avatar
bdehning
Post Prodigy
4 years ago
Solved

Calculate Percentage

I have a column called "Claim Status"   Rows are either "Open" or "Closed"   

Each row has values of "Total Outstanding" in dollars and "Total Paid" in dollars.  

 

I want to calculate the % paid for Open for a Field in Power BI when the rows are "Open"  So for sample below, just get the $12,964.98  Divided by $25,179.03 for 49%

 

Claim StatusTotal Gross IncurredTotal Outstanding Reserve
Closed$759.05$0.00
Closed$14103.64$0.00
Open$25179.03$12964.98
Closed$466.30$0.00
Closed$0.00$0.00
  • This should be a straightforward DIVISION operation.

    What is the NUMERATOR? [My Numerator] = CALCULATE ( SUM ( [Total Outstanding Reserve]), [Claim Status] = "Open")

    Similarly, the DENOMINATOR: [My Denominator] = CALCULATE ( SUM ( [Total Gross Incurred]), [Claim Status] = "Open")

     

    And finally: [My Percentage] = DIVIDE ( [My Numerator], [My Denoiminator], 0 )

  • Yes, that work perfectly after I entered in correct Syntax and did the Divide.  

5 Replies

  • bdehning 

    If you need to create a column in the table, add the following column:

    % Open =
    IF (
        TableName[Claim Status	] = "Open",
        DIVIDE (
            TableName[Total Outstanding Reserve,],
            TableName[Total Gross Incurred]
        )
    )
    
  • This should be a straightforward DIVISION operation.

    What is the NUMERATOR? [My Numerator] = CALCULATE ( SUM ( [Total Outstanding Reserve]), [Claim Status] = "Open")

    Similarly, the DENOMINATOR: [My Denominator] = CALCULATE ( SUM ( [Total Gross Incurred]), [Claim Status] = "Open")

     

    And finally: [My Percentage] = DIVIDE ( [My Numerator], [My Denoiminator], 0 )

  • When tyring to create Numerator Measure, I can not see or select Claim Status as it is a Text Field?

    • ToddChitt's avatar
      ToddChitt
      Super User

      Can you show us how the three elements are related? Maybe throw in a screen shot of the relationships? The fact that you cannot 'see' [Claim Status] in the measure calculation has nothing to do with it being a text data type and has everything to do with the design of the model, the relationhsips, cardinality, cross filter directions, etc.

  • Yes, that work perfectly after I entered in correct Syntax and did the Divide.