So I have a monthly budget in Excel that I'm using to keep track of making sure all of my recurring bills get paid on time.
Let's assume I have a table formatted like this:
Bill | Due Date | Amount Projected | Actual Amount | Diff
Mortgage | 1st | $1,500 | $1,510 | -$10
Water Bill | 13th | $30 | $25.80 | $4.20
I get paid on the 1st and the 15th, and I'm trying to get two rows that give a sum of all of the bills that are due within the first paycheck, and a sum of those that are due after.
So I'm trying to use the SUMIF function, however because the DUE DATE column is text and not date so that I get the 1st, 2nd, etc, I'm not sure how to run a comparison on this.
So I have the formula to get rid of the th, nd, etc as:
=LEFT(B2, LEN(B2)-2)
If it didn't have the th, or nd, the SUMIF function would look like this:
=SUMIF(C2:C3, "> 15", B2:B3)
But I just can't figure out how to combine the two formula. Is there any special character that runs the transform on the cell where I can pass that into the formula, without having an intermediate cell somewhere to just hold the 1, or 13 for the date due?
I know there are other ways to do this like just sorting the columns by due date and then only selecting that range, but I'd like to not have to manually change a bunch of other "reporting" columns every time I add or remove a bill.
Thanks for any help in advance.
=SUMPRODUCT((left(B2:B3,len(B2:B3)-2)<15)*C2:C3)
SUMPRODUCT performs array like operations. As such avoid using full column reference such as B:B.
Related
Lets say I have a table in sheet 2:
my headers go
Program | start year | Salary | meets some expectations | meets all expectations
business | 2017 | $50,000 | $0 | $1,000
finance | 2016 | $60,000 | $0 | $2,000
treasury | 2015 | $80,000 | $0 | $5,000
In another sheet (sheet1), I have a roster where I need to pulls in salary data based on that table. So, if employee 1 in row 1 has a start year of 2015, it'll pull over her planned salary of $80,000. Employee 2 in row two started in 2017, so their planned salary will be $50,000.
how can I use an index/match to pull over the correct planned salary? I feel like this is a long-winded IF statement to trigger an index/match value, but I don't know where to start.
Second part to this, how can I implement an IF statement to pull over the incentive numbers?
example:
employee 1 business 2015 meets all expectations would receive a $5,000 incentive.
This table I made has only one business segment, there are dozens, so I'm sure that would factor in. Can this be done?
With the data you gave in your example, this formula can work (enter with CTRL+SHIFT+ENTER):
=INDEX($A$2:$E$4,MATCH(B7&C7,$A$2:$A$4&$B$2:$B$4,0),MATCH(D7,$A$1:$E$1,0))
I don't think you need multiple criteria to simply pull through the salary.
Can you not just do this:
=INDEX($K$5:$K$7,MATCH($D4,$J$5:$J$7,0))
To get the incentive value based on start year AND performance, you can use an INDEX/MATCH/MATCH:
=INDEX($L$5:$M$7,MATCH($D4,$J$5:$J$7,0),MATCH($F4,$L$4:$M$4,0))
EDIT: To allow for different programs without an array formula:
=INDEX($L$5:$M$7,MATCH(1,INDEX(($C4=$I$5:$I$7)*($D4=$J$5:$J$7),0,1),0),MATCH($F4,$L$4:$M$4,0))
The trick here is in first MATCH formula, which checks both the Program and Start Year:
MATCH(1,INDEX(($C4=$I$5:$I$7)*($D4=$J$5:$J$7),0,1),0)
I'm attempting to calculate periods of out of stock for a fleet of rental equipment that has been in service for the past few years. I'm having trouble creating a sumif calculated field that sums units by date if date is between start and finish. My data looks like this:
Calendar |Start |Finish |Product |Units
2015-12-06|2015-12-6|2015-12-6 |Snowshoes |2
2015-12-07|2015-12-6|2015-12-7 |Snowshoes |1
Calendar - is a helper column I've added. It's sequential dates from launch to the present
Start - is the start Date of a rental booking
Finish - end date of the rental booking
Product - What's being rented
Units - How many are rented for that booking
I'd like the pivot table to look like:
Date | Snowshoes | Tent ... etc
2015-12-06 | 3 |
2015-12-07 | 1 |
I'm having a hard time setting up calculated field that will sum units if date is between start and finish, I keep getting formula errors.
Here's the formula I'm attempting to use to create a calculated field:
= sumifs( Units ,Start,">= Calendar" , Finish,"<= Calendar")
Is this even the best way to go about solving this problem? Is my formula the issue or is the entire approach flawed?
Adding screenshots:
From the data you have in the screenshots, this is what I came up.
The formula to use in column G:
=SUMIFS($E$2:$E$29,$A$2:$A$29,"<="&F2,$B$2:$B$29,">="&$F2)
The formula to use in column H (BTW, this is just for your reference. You can use either one of them):
=SUMPRODUCT(--($A$2:$A$29<=F2),--($B$2:$B$29>=F2),$E$2:$E$29)
From here, I created a Pivot Table like this:
Hopefully this can help you. But definitely let me know if I miss anything from your question.
We've got data in Excel that looks like this:
| A | B | C |
—————————————————————————————————————————
1 | Amount | % Complete 1 | % Complete 2 |
2 | $ 1,000 | 25% | 50% |
3 | $ 600 | 50% | 100% |
4 | $ 2,500 | 75% | 100% |
Each line item is the cost of a task we've agreed to pay and each "% Complete" column is the percentage complete as of a specific date. We sum up the amounts owed as of that date to pay them based on the percentages, meaning that for the first "% Complete" column we can calculate the amount owed by using the array formula {=SUM(A2:A4*B2:B4)}.
However, subsequent columns need to pay only the difference between what's currently payable and what was already paid before.
To complicate things further:
The data will be blank if there was no change. For example, if something's 25% done as of the first check and still 25% done as of the second check, the corresponding cell in the second check's column will be blank.
The percentages can go down, leading to a negative amount to be paid. For example, if something's 50% done at the first check but progress goes backwards, the second check might have that at 25%, which means money is due back to us.
So for "% Complete" columns after the first, I need the last non-blank cell in the same row in a "% Complete" column prior to the current column. Using this explanation, I was able to create a formula that does that:
=$A2*(C2-LOOKUP(2,1/($B2:B2<>""),$B2:B2))
This will calculate how much is payable for a particular cell, so in the example above, it will produce $250: $1,000 * (50% - 25%). It will keep working as you continue along and will handle finding the last non-blank column.
I'd like to use the above formula in an array formula, but can't figure out how to do so.
So that gets us to the question: when a formula already has a range in it (i.e., the $B2:B2 in the formula above), is it possible to use that in an array formula and, if so, how? In a normal formula, you could covert a cell reference (e.g., A1) into a range (e.g., A:A), but is there some kind of syntax to use a range within a range?
Also happy to consider completely different ways to solve this problem, but due to how this spreadsheet is used, we unfortunately cannot use VBA.
To answer the last part of your post, I assume you will be updating and calculating the progress and payments periodwise. In which case, all you need to do is compare the current period with the previous. If such is the case, using the IF() function in a form something like this should serve the purpose.
=IF(Compl2>Compl1,Compl2*Rate,(Compl2*Rate-Compl1*Rate))
Everyone,
I have an excell sheet which I have imported from my ERP program. It contains data about deviations in raw materials which were noted at specific dates.
There are 40 different materials and data was gathered throughout the last year.
The raw data looks like this:
Material name | Date | Deviation
Blue dye |2014.05.01| 50
Yellow dye |2014.07.02|-40
Blue dye |2014.07.04| 10
How can I transform this data to a stock-type chart which would should cumulitive deviations throughout the year (i.e. if Blue dye is always positive, how much had added up on each date).
I have figured out how to sum up the deviations with their previous values, I have also transformed the table so that all the materials have their deviations in a seperate row:
Material name1|Date1|Date2|Date3
|50 |-10 |20
Material name2|Date2|Date5|Date6
|5 |10 |-100
The problem is that the deviations don't happen on the same dates. If they were noted on the same day every week, this would be hard at all. In this case each material might not have a deviation for a month or two, while another has fluctuations every couple of days. I would need to somehow interpolate the data in between the dates, so that every day of the year is filled up.
I would appreciate any ideas, at this point I'm just stuck...
I thought the above may have been a little vague...i've done you a quick example at the link below - there are 3 tabs
1 for the raw data
2 to get the differences by date & material
3 to show stock holding each day by material (with no change should there be no change)
Assuming you wanted to graph this info by date/product you should have no problem doing this from the example.
hope this is of more help!
http://www.filedropper.com/materialexample
I would suggest using the original data but creating a table on a new tab, list the entire year in column A from A2 down then list the 40 materials across in B1,C1,D1...etc
Then Starting in first cell (B2) use SUMIF(AND functions to match the date in A2 and the material in B1. if there is a match then +/- the difference...perhaps start one cell lower down and use B1,C1 etc for the starting number to perform calculations...this should give you the holding at any one point.
Hope to have helped :)
The Total Amount is incrementing(single cell:H2) when value is entered in the same cell(G2)..e.g today if you enter in G2 the value of 30 the total amount in H2 is 30;when you enter tomorrow in G2(same cell) the value of 50, the total amount in H2 should be 80;and when you enter again 80 in the same cell(G2)the next day, the total amount should now be 160...hope you could shed a light on this...Thank you very much...
UPDATE:
I found this to be working, no VBA required. It should be quite simple actually. Start with your file like this:
| | G | H |
|---+-------------+-------------------|
| 1 | Amount paid | Total Amount Paid |
| 2 | 0 | 0 |
Now go to your settings (for 2010 File -> Options -> Formulas, for 2003 Tools -> Options -> Calculation), tick 'Enable iterative calculation' and set 'Maximum Iterations' to 1. Now in H2 enter your formula as =G2+H2. This is a circular reference (the simplest one there is, cell H2 refers to itself in the calculation) which won't work properly unless you set your calculation settings right. If you set your calculation in the same settings tab to manual then the total will only update when you press F9. If you set it to automatic it will automatically update when you make a change in cell G2.
Original answer
Assuming your data starts in A1 this formula would sum up all numbers in column A
=SUM(A:A)
If you won't have other stuff in this column (and don't mind the obvious overkill) this will work. If you need to be a little more specific and update a range that dynamically grows/shrinks we need to be a little bit more clever and use INDIRECT or OFFSET as follows
=SUM(INDIRECT("A2:A"&COUNTA(A:A)))
=SUM(OFFSET(A2,0,0,COUNTA(A:A)-1,1))
If you don't know these functions look into them in the Help, they can be very useful.
Another thing to clean things up would be to define a named range with the above e.g. OFFSET formula piece and use that in your formula(s). This makes it easier to repeatedly use the specified range and improves the readability of your formulas. I would define PaidRange as follows
=OFFSET(A2,0,0,COUNTA(A:A)-1,1)
and then your formula would read
=SUM(PaidRange)