Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Help with calculations

I need to create a line chart with monthl by month figures.  I get a report each month that I need to complete multiple steps in Excel to create this chart.  I want to be able to create this in Power...
  • Anonymous's avatar
    Anonymous
    6 years ago

    Hi,

    I did this in two measures. Hope this helps!

    UnitTotal = SUMX('Table', 'Table'[L25]+'Table'[L27])
    
    Monthly Total = 
    VAR PrevMonthUnitTotal = CALCULATE([UnitTotal],
                             PREVIOUSMONTH('Table'[Report Date])
                             )
    Return
    IF(SELECTEDVALUE('Table'[This Month]) = "October",
        [UnitTotal],
        [UnitTotal]-PrevMonthUnitTotal
        
     )

     

    ~Kim