I am trying to use a circular reference with iterative calculations to find a specific number however my file will not display the number. I turn iterative calculations but it fluctuates wildly even though there is a definitive answer. I have included an image of my example.
In general, circular references are a result of an incorrect structure in formulas. Enabling iterative calculations is not a solution to this problem. They are only intended in situations where repeatedly performing a calculation will lead to stable result.
(An example of useful iterative calculations is field analysis. You can define values around the edge of a field of any shape. In the interior, the value of every point is the average of all the points around it. After several thousand iterations, everything will stabilise to an evenly distributed field.)
In your situation, iterative calculations does not lead to a stable result. When Ending Cash is -300, the Cash Deposit is set to 300. But then the Ending Cash is 0, so the Cash Deposit is set to 0. But then the End Cash is -300, so the Cash Deposit is set to 300, ad finitum.
The calculation of how much Cash Deposit is required to ensure the End Cash is greater than or equal to 0 can't be based on the End Cash or the Total Deposit, as it will keep contradicting itself as to whether or not a Cash Deposit is required.
Instead, the calculation of how much Cash Deposit is required must look at all other deposits excluding itself and compare that to the total withdrawls. (By not referring to the Total Deposits or End Cash, there is no circular reference). It can be set up as:
=IF(B2+B5<B14,B14-(B2+B5),0)
It adds together all other Deposits excluding itself and compares that to the Total Withdrawals to determine whether any additional deposit is required. If an additional deposit is required, it then subtracts all other Deposits from the Total Withdrawals to find out how much it needs to be.
A more elegant way of writing such a formula is:
=MAX(B14-B5-B2,0)
This simply subtracts all deposits from the total withdrawal, and returns the difference if it is needed when it is positive (more withdrawals), or returns 0 if it is not needed when the difference is negative (more deposits).
Related
When using XIRR to calculate the performance of a stock trading account, do you need to have a beginning cash flow equal to the starting balance of the account (seed money) ?
When I do that, it throws the formula completely for a loop and I either get errors because it can't calculate the return, or the return is very, very negative despite the account actually increasing in value over the year.
$7,000 starting balance/seed money, entered as a negative, January 1st
$6,800 invested in a trade, January 2nd
$8,000 deposited from closing the trade, December 22nd.
The ROIC on the trade would be 17.6%, and the MWRR should be about 17.1%, +/- 1% since the investment period was slightly less than a full year.
But XIRR is returning -43%?! If I tell XIRR to ignore the seed money, and only look at the amount invested in the trade and the amount received when closing the trade, I get just over 18%, which seems right.
What am I not understanding about XIRR? I thought all IRR needed to include the seed money?
I am trying to build a bit of a tracker within Excel/Google Sheets to identify which 'home loan' has the combination of highest interest rate PLUS loan/mortgage size.
The formula I've built so far works for the below conditions;
There is only 1 loan with the highest interest rate, or;
If there are multiple loans that have the highest interest rate, the loan that is the largest is included within that condition.
Where this formula doesn't work is when;
When there are multiple loans with the highest interest rate, however these loans are NOT the largest loan size... I believe the issue is due to the fact I'm including a 'max' statement as part of the match condition. Please see cell reference I8:L10 as an example.
I'm unsure how to achieve this within a formula to identify;
The loan with the highest interest rate
Of the loans with the highest interest rate, which has the largest mortgage/loan size.
Please note the Interest Rate's vary within the data set
Formula Used:
=if(countif($E3:$H3,max($E3:$H3))>1,
if(iserror(index($E$1:$H$1,match(1,(max($E3:$H3)=E3)*(max($A3:$D3)=A3),0))=I$1),"Inactive","Active"),
if(index($E$1:$H$1,match(max($E3:$H3),$E3:$H3,0))=I$1,"Active","Inactive"))
Link to spreadsheet
https://docs.google.com/spreadsheets/d/1GHN8-uX4RdkMz0IIvTTxB0TjAKtUMSdCTFHqXNgHVm4/edit?usp=sharing
Thanks in Advance!
You can use =FILTER($E3:$H3,$E3:$H3-Max($E3:$H3),"") to create an array of all loans with the highest interest rates. I suppose it ought to be possible to create a matching array of loan sizes and then extract the highest of these. However, the task appears intimidating.
Meanwhile I wonder if this much simpler approach will allow you to get to your desired result using simple IF functions.
=IF(A3=MAX($A3:$D3),"Hi loan","Low loan") & " / " & IF(E3=MAX($E3:$H3),"Hi Rate","Low rate")
You chose "Active" and "Inactive". I chose "Hi" and "Low". Both of these are translations of True and False and may be used in conditional formatting, for example, where you simply highlight loans with the highest interest rate in one colour, and choose a different colour where the highest rate is applied to the largest loan. The simple logic I express here can be expressed in words, too. It's just a matter of interpreting the two results provided by my formula to best suit your needs.
I have a simple spreadsheet that calculates the mortgage payment (using PMT) once user enters some key fields. I am also calculating the housing ratio (B9) which is the mortgage payment(B6) divided by income (B7). I am comparing the housing ratio to the maximum housing ratio (B8). There are many times when the housing ratio (B9) exceeds the maximum housing ratio (B8) and I need a formula in cell B11 that will tell me by how much I have to reduce the loan amount in (B3) to NOT exceed the maximum housing ratio in B8.
Can someone help me out with the correct formula?
Being that this is a pretty simple calculations, I'd suggest just doing it manually using iterative calculation.
First, enable iterative calculations for your workbook via File > Options > Formulas > "Enable iterative calculations."
Then, edit the formula for the loan amount to be (sale price * LTV) - reduce by
Doesn't take long the enter a few different numbers in for the "reduce by" to find it needs to be reduced by ~$6786.
If you want to make it a little more clear you can add another row under Loan Amount like so:
I am working in an Excel workbook where a monetary value is displayed. This amount is the difference between two constants, and represents a shortfall in a customer's payout, for which we need to compensate customers.
I need to work out the required compensation amount from this.
Customers are entitled to some compensation only if their shortfall > £1.00. We only compensate them up to that level (shortfall - £1). We have a minimum payment amount of £0.50.
So, to calculate the compensation required, I think I need to apply the following logic to the shortfall number :-
Shortfall is greater than £1
AND
Shortfall minus £1 is GREATER THAN than 50p
This is two steps and I think there is an easier, cleaner way.
I think this could be described as y = x - 1 > 0.5
I would have to use an AND function to do this, but I am sure there is a simpler way to describe this using one simpler function.
I have just completely unable to get my head around it though.
Can anyone help?
Shortfall is greater than £1 AND Shortfall minus £1 is GREATER THAN than 50p equates to shortfall must be greater than £1.50
I have a data matrix depicting the number of telephone calls from one telephone to another, all calls are unidirectional. The rows represent days and the columns represent hours. The data is not a sample - it is the full population. Rows are days of the week and columns are one hour blocks of a 24 hour clock. Values in the cells represent the number of telephone calls from telephone A to telephone B for that specific hour.
I would like to have a repeatable measure that enables me to tell my audience that the likelihood of this distribution occurring randomly is <x.
I'd like the formula for Excel 2007 or, as a last resort, VBA code.
I've searched and found answers that tell me how to statistically determine the significance of differences between two different data sets but not how to measure for just one data set against a random outcome.
Thanx in advance.
If the total number of calls in a given hour is T, and the total calling population is P; then the number of calls from A to B should be about T/P if "random". To test whether this is really the case you'd use the Chi-squared test. I'm afraid I don't have time to give you the full answer - but it'd be the testvalue=sum((observed_i/P - (T/P))^2/(T/P)) where you check the testvalue against the chi-squared table, and you can pick off the probability too. Excel can calculate these values. Refer Chi-Squared Test for more details.