I have a large control sheet in Excel with over 1000+ students on it. I have three columns that I want to use which are (Start of 2 year study period - column 1), (End of 2 year study period - column 2) and (Pass/No Pass - column 3)
When a learner registers with us we will type in the start date of registration in the first column and then +730 for the 2nd column giving us our end date.
In the pass no pass column each learner has to complete units and when they pass this unit I mark it as a pass.
What I want to try and achieve / find out is pass rates either
A. per year or
B. every two years (registration period)
For example if I registered say 200 students between 01/01/2015 and 01/01/2017 I want to know what the code for that would be - if there is any code.
Something like =COUNTIF(C:C,"Yes")/(COUNTA(A:A)-1) would do it where "Yes" means they have passed (if you want, you can change this to "passed" etc.).
The above formula puts the total number of "Yes"'s over the total number of people registered (COUNTA(A:A)-1 counts all cells with an entry and then takes away the header)
Here's what it's look like:
EDIT: Please forget the dates entered in column B - I just entered random dates so these aren't correct but the formula works perfectly regardless.
If you want to do an analysis per year you can use the following helper column D.
Column A: Start date formatted as date (localization doesn't matter)
Column B: =A:A+730
Column D: =YEAR(A:A) (format as standard or number)
G3: =COUNTIFS(D:D,"=2016",C:C,"=Pass")
G4: =COUNTIFS(D:D,"=2016")
If you need a 2 year analysis (eg. 2016+2017) do an analysis for both years and add them up later. Then calculate the rate.
Related
My excel knowledge is very basic using my own research here and there so I would need some help from you guys.
I have a situation where I need to calculate the number of rows that contain certain date values which I converted it to text for certain reason (didn’t want to list them in separate rows).
E.g.
Col A. Col B.
Customer Name, Date Purchase
Andy. 1/2/2021 , 2/3/2021
Jenny. 2/2/2021 , 3/4/2021
Mary. 1/3/2021 , 1/5/2021
I want to count the number of unique customers who purchased between February and May 2021 for the above case, but I didn’t know how I should proceed from an existing countifs formula I had that looks like the following:
=countif(B:B, “/2/2021”) + countif(B:B, “/3/2021”) + countif(B:B, “/4/2021”) + countif(B:B, “/5/2021”)
This formula had returned the value as 9 based on the following results
February : 2
March : 2
April : 4
May : 1
which I didn’t want as I want the count number of different customers I had instead (for this case I want the cell with a formula that can return the result as “3” , not the number of time purchased).
Please help me to make a suitable formula works! Thanks 🙏
By adding an indicator in Column C that shows whether or not each customer satisfies your purchase requirements you could simply sum these up at the bottom to count the number of unique customers.
Hopefully the image below containing the formula in Column C (essentially checking that each customer has at least one purchase between February and May) will resolve your issue. I added a Dummy customer that doesn't satisfy these dates just a check so the total unique customers is still 3 (Cell C6 which uses a formula of '=COUNTIF(C2:C5,"Y")').
You mention the possibility of having 100 purchase dates, are these all recorded in text format in Column B? I would have thought that would make things more difficult to track than having 100 individual columns (though this doesn't affect your query above).
I'm trying to set up an excel sheet which displays the name of the person available at the current time and date. I have one sheet with a list of dates and times along with the persons name who is available at that time. For example:
- 01/07/19 09:00 Bob
- 01/07/19 10:00 Bill
- 01/07/19 11:00 Ben
I can do this successfully for a full day or week using the WEEKNUM or DAYNUM functions, and the week/day number listed against the list of names.
I can use NOW() to get the current date and time, but I'm unsure how I can use this to get the desired results.
I've tried searching online for the answer but have been unable to find what I'm looking for.
Based on my example above, if the current time is between 9:00 & 10:00 I want the name Bill to be displayed.
Based on your dates being actual dates stored as number for excel and not numbers stored as text, and same for time, then the following solution should work for you. You can test your data to see if its an actual date using:
=ISNUMBER(A2) `where A2 is the cell in question
If the formula returns true then you know your are dealing with a number that has been formatted to display as a date or time.
As a side note, dates are stored as integers and are the number of days since 1900/01/01 with that date being 1. Time is stored as a decimal representing the portion of the day. 0.5 would be 12 noon.
This solution assumes the data is layed out as per the image below.
In cell F1, place your NOW() function. I have manually entered the date to control the value for demonstration purposes.
In cell F2 enter the following formula:
=INDEX(C:C,AGGREGATE(15,6,ROW($A$2:$A$4)/((INT($F$1)=$A$2:$A$4)*(MOD($F$1,1)<=$B$2:$B$4)),1))
AGGREGATE will make a list or all row number and sort them from largest to smallest. All Those row numbers will be divided by your criteria checks. If your criteria results are ALL True, then the row is divided by 1 and remains unchanged. If a criteria is not met the Row number is divided by 0 which causes an error. The 6 in the function tells aggregate to ignore error results. So you wind up with a list or row numbers that march your criteria. The 15 in aggregate tells aggregate to sort the row numbers from largest to smallest. The 1 tells aggregate to return the row number in position 1 of the sorted list. Aggregate then passes that row number to INDEX which finds the row in the corresponding column and returns the address of that cell.
now just so you are aware. The break point for time was set so that the person beside the list time is the one that will be picked when that exact time is provided. Meaning for a time of 0900 on the specified day, Bob would be selected. At 10:00:01 Ben will be selected. At 11:00:01 an error will be generated. you can control this by placing the whole thing in an IFERROR function. At 00:00:00 Bob is selected.
I believe this will do what you want:
=INDEX(C2:C4,MATCH(NOW()-TODAY(),B2:B4,1))
Where column C contains the names and column B the times
If date and time are in one column, you can try:
=INDEX(B1:B3,MATCH(NOW(),A1:A3,1))
Where column B contains the names and column A the date and time
Here is one way:
Formula in F1:
=INDEX(C2:C4,MATCH(1,INDEX((A2:A4=TODAY())*(HOUR(B2:B4)<=HOUR(NOW()))*(HOUR(B2:B4)>=HOUR(NOW())),0,1),0))
What's happening? We use MATCH to get the first TRUE in an INDEX list that compares column A against TODAY times column B for HOUR.
We can leave out the second INDEX but that would make it an array formula to be entered through CtrlShiftEnter
Note that this example is made around 9:30 on the 4th of July.
Hy Every One, I need help in excel formula, I have two sheets, sheet1 for sale tracker, sheet two for goals tracker, I used Now() to enter date automatically, and its working fine, Next in goal sheet, I use =Sumif() to calcualte various category totals and refer them in cell. Its also working fine. But I want to track record according to month and category. Like I have 6 categories detail is as under,
Sales Tracker
In the First picture Column Date consist of formula "=IF(ISBLANK(B5),"-",TODAY())" and it display the name of month like "October"
While in second picture there is a drop down list of "Month" Column.
1- I want to use if statement like =if(Date=Month, Sum(Revenue Secure column Data), "-") But its not working the formula I wrote here is an example....
2- I want when I select any month from second sheet like January, February, It should calculate sum from picutre one data and only show the sum of january etc.
Please help me, this is eating my brain a huge,,,,,,:)
Thanks in advance....
In short my question is how can I use If statement to compare value of cell that contain formula and other that contain drop down list?
Or use the MONTH function to change your date to a number 1 to 12 corresponding to the month. Then have the combo return a number for the month chosen. It might be faster using integers than test
I Believe you have to compare the month and not the whole date.
You can do TEXT(NOW();"mmmm") to get the full month name of the current data (in the language of excel) and then compare it to your drop down.
If you replace the NOW() with any data it works as well.
I'm trying to work out the maximum number of times a user has accessed the system in a day. There are different dates that they have accessed the system but on some days they have accessed the system more than once and I want to find the day with the highest number.
There are 4 columns: 1. Name (A) 2. Date (B) 3. Total Daily Accesses (C) 4. Highest number of times accessed in a day for each user (D)
I've copied in the formula below which isn't displaying the highest number of times accessed in a day:
=MAX(C:C,A)
If anyone could advise where I am going wrong, I'd really appreciate it.
Thanks
1) Generate a list of unique names using this formula modified to suit your ranges:
=INDEX($A$2:$A$20, MATCH(0, COUNTIF($B$1:B1, $A$2:$A$20), 0))
The above formula taken from this question
2) Assuming you generated the list of names in column F and lets assume the range F1:F10
=Aggregate(16,6,(A:A=F1)*C:C,1)
Copy that down as far as your list of unique names goes.
Let's assume the names are in column A, the date in column B; one line per user and date, multiple users, possibly multiple dates. For the formulas, let's assume data in rows 2 to 22.
We need an auxiliary column to hold the combination of name and date, like in column E:
=A2&B2
for cell E2.
To list the total number of daily logins for each user, put in column C
=COUNTIF($e$e:$E$22,$A2&$B2)
Copy this down for each row holding data.
To get the maximum daily events per user, create the list of users in column F (either manually, or using the answer cited in another answer here). Into each line of the list of users, enter
=MAX(IF(A2=A$2:A$22;C$2:C$22))
as an array formula (close with Ctrl+Shift+Enter).
I have a few record of company. Below is the sample of it but sometime the record might hit 400 company.
I want to sum up the amount before 2013. meaning that sum up everything include 2012, but I want each individual company have sum of its own.
=SUMIF(A:A,"<=2013",B:B)
Assuming Column A contains the year only (do this by using a helper column to seperate the year eg. =text(C1,"YYYY") copy that all the way down (assuming date is in column C) then format the cells as number
Column B contains the data you want to sum
Criteria <=2013 will sum all values less than 2013
Hope this helps...
Apologies...for each company to have its own SUM use the following
=SUMIFS(B:B,A:A,"<=2013",C:C,E1)
B - values you want to sum
A - year only (as per first answer)
C - Company name column
E1 (in this case) references the company name eg:
E1 - Company 1
E2 - sumOfCompany1 goes here
Hope this is more what you're looking for.