My model is made up of month end actual balance sheet balance and associated interest rates and I’m looking to compare month on month change in both balances & weighted rates (earnings). The data is organised at account level aggregating up into different summarised levels.

I have created the measure ‘Current Weighted Rate’ for the current month as follows which works ok:-

```
CM Weighted Rate =
DIVIDE(
SUMX('Margin&BalanceSheet','Margin&BalanceSheet'[interestbalance]*'Margin&BalanceSheet'[interestrate]),'Key Measures - Current Month'[CM Interest Balance],0)
I’m now trying to create the same measure for the previous month as follows but I get an error.
LM Weighted Rate =
DIVIDE(
CALCULATE(SUMX('Margin&BalanceSheet'[interestbalance]), DATEADD('Margin&BalanceSheet'[interestrate],-1,MONTH)) *
DATEADD('Margin&BalanceSheet'[interestrate],-1,MONTH),
CALCULATE(SUMX('Margin&BalanceSheet'[interestbalance]), DATEADD('Margin&BalanceSheet'[asatdate],-1,MONTH)))
Too few arguments were passed to the SUMX function. The minimum argument count for the function is 2.
Other expressions for previous month balances work fine
LM Interest Balance =
CALCULATE(SUM('Margin&BalanceSheet'[interestbalance]), DATEADD('Margin&BalanceSheet'[asatdate],-1,MONTH))
```

Any suggestions would be appreciated.