Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Conditional Index

Dear all, I'm happy to be a new user in this forum. I face an issue and I couldn't found a solution for this problem yet. I have the following problem. I want to create a Burn-Down Chart based...
  • Jihwan_Kim's avatar
    4 years ago

    Hi,

    Please check the below picture and the attached pbix file.

     

     

    Actual CC =
    VAR _startdate =
        MIN ( Data[Date] )
    VAR _startnumber =
        MAX ( Data[Planned] )
    VAR _conditiontable =
        ADDCOLUMNS ( Data, "@condition", IF ( Data[State] = "Closed", -1 ) )
    VAR _cumulatecondition =
        SUMX (
            FILTER ( _conditiontable, Data[Date] <= EARLIER ( Data[Date] ) ),
            [@condition]
        )
    RETURN
        _startnumber + _cumulatecondition
    
  • SpartaBI's avatar
    4 years ago

    Anonymous this is another alternative, but Jihwan_Kim solution is also great.

     

     

    Actual CC = 
    VAR _startnumber =
        MAX ( Data[Planned] )
    VAR _minus_count =
        COUNTROWS(
            FILTER(
                Data, 
                Data[Planned] >= EARLIER(Data[Planned]) && Data[State] = "Closed")
        )
    VAR _result = _startnumber - _minus_count
    RETURN
        _result

     

     

     







          

    Showcase Report – Contoso By SpartaBI