Excel Forumula - How count last 7 cell in a column? - excel

I would like to get help on how to write a formula that would count the values in the last 7 cells of my column.
Is someone can help me on this ?
thanks

Not sure if this is the most optimal solution, however, it should work to sum up the values of the last 7 cells in a given column (in my case, column A):
It assume no blank cells in the list ...
=SUM(OFFSET($A$1,COUNTA(A:A)-1,0,-7,1))

Related

Is there a way to filter two columns which either of the value in column is greater than 20?

I have a TSV/excel flle with numeric data. I want to filter out all the row from which either column "A" or "B" should have values greater than 15.
I tried to get the sum of the column in an additional column and filter, but it doesn't make sense if cells contains 7 and 8. also average of the column also not working if the cells has 20 and 5.
Data I have:
Result I need
I'm very newbie to excel,Please help
Thanks in advance
The easiest way is to create a helper column, containing following formula: =OR(A2>=20,B2>=20). (Start at cell C2 and drag further down)
Filtering on this helper column (value TRUE) will result in this screenshot:
If you have Excel 365 you can use the new FILTERfunction:
=FILTER(A2:B8;(A2:A8>15)+(B2:B8>15))
It will spill down all rows that fulfill the criteria.
The +-sign reads as OR for the conditions.

Excel formula to count number of lines (not necessarily rows) in all non-blank cells in a column

I'm looking for a formula to count how many lines are in non-blank cells in a column. For the image below, I would like the formula to return 11.
Any help with this would be appreciated!
Try,
=COUNTA(V:V)+COUNTIF(V:V, "*"&CHAR(10)&"*")
=COUNTA(A:A)
Assuming the column is A, if it's a different column change A:A to whatever it is.

EXCEL: Count a cell if cells relative to it have certain values

What I want to do is count the cells with any number value (=count) in the last column (F) IF the cells in the same row have certain values. For example, let's say I want the first column (A) to contain "Bleach", the second to contain ".05", and the third to contain "2". I only want to count the cells in column F if those cells in the same row have those values.
I have no clue how to do this, so any help is appreciated.
If layout allows you, create a new column that has a formula like if (and(a = 'bleache',b=0.5,c=2),1,0) and make the count on this column and hide it afterwards.
Also I saw a new formula (never used it personally) you should check it:
http://office.microsoft.com/en-001/excel-help/countifs-function-HA102753238.aspx?CTT=1
Excel does have a COUNTIF function that does exactly what you're looking for.
You specify a range and a criteria. If the criteria is true, then the value is counted.
Please try:
=SUMIFS(F:F,A:A,"Bleach",B:B,0.05,C:C,2)

A formula in Excel to count the number of rows where there is a date in column 'K' but column 'N' is blank?

I am a little rusty to say the least and in Excel I would like to create a formula that counts the number of cases that have been closed without a certain stage taking place.
So, the formula would need to count the number of rows where there is a date in column k, but no date in column n (the cell is blank). Any help would be appreciated. I have had a go with COUNTIFS and SUMPRODUCT but I'm not getting anywhere.
Try this
=COUNTIFS(K:K,">0",N:N,"")
that's counting rows where K is greater than zero but N is blank [""]
If you can use another column try this formula, for every row of the column:
=IF(K1>0,1,0)*IF(N1="";1;0)
then you have to sum column values.
Instead of K1>0 you can use two cell for date so you can count cells within a range of date.
For a start try something like:
=SUMPRODUCT((K1:K100<>"")*(N1:N100=""))

Using SumIf to add cells instead of range of values

I currently have a situation wherein I am required to subtract 2 cells. 1 cell is already known but the second cell is to be found from a range. I have seen this can be done using the SumIf but among the range,criteria,sum_range factor, I dont know how to mention the sum_range as 2 distinct cells.
Also, point to be noted is that these 2 cells needed to be subtracted are in 2 different sheets in the same excel workbook.
I was trying using this below
=sumif(AC1:AC3,Sheet1!AA14,Sheet2!S1 - Sheet1!S14)
But it gives error. Can someone help. Am trying to match Sheet1!AA14 with any one of the values in this range AC1:AC3. And for the a perfect match, it would subtract the corresponding sheets "S" cells
please help
I suggest you try using VLOOKUP if you have the first value of your subtraction equation. Here is an example (sorry I don't understand your setup enough to use your cell numbers):
A B C D
test 20 15 test
test1 10
=VLOOKUP(D1,A1:B2,2) - C1 ' results in 5 (20 - 15)
Look for value in D1
A1:B2 is the range with the value and the data you want back. 1st column is the search column.
If it finds the value it will give back the value in the 2nd column of the range, in this case B.
You then take the value and subtract the value in C1 from it.
Check out MS's documentation on VLOOKUP and mess around with it. Best of luck.

Resources