Worked days count - excel

I have a monthly report on google sheets(excel format) that I am trying to to fix. So I have 17 workers. The formula that Iam trying to make is, it should count how many days workers worked in a month. Workers day-offs are not obvious(we decided everyday) it shows in the graph, name, job location or day-off Screenshot
it is in P column and i tried to write this formula:
=If(And("P2,P21,P43,P65,P86,P103,P123,P144,P165,P186,P207,P228,P249,P270,P291,P312,P333,P354,P375,P396,P417,P438,P459,P481,P502,P523,P545,P566,P588,P609,P630","x=1","x=off=0"))
I know this is not correct, does anyone know how to put it together? this formula is only for one worker, for others I will copy paste

The function you're looking for is networkedays
https://support.google.com/docs/answer/3092979?hl=en
Please note that if you're using Google spreadsheets you should tag your question appropriately (there are some similarities but it's not identical)

Related

Excel formula to return a unique count based on multiple criterias

I have a Gantt chart in Excel, which hosts a lot of functionality. The main issue is that smallest task duration has to be a day, however there are certain tasks that can be done in a couple of hours. I'm trying to count the actual duration of days taken across the entire project, for a given type of task.
See sample below.
The following tasks shown on the screenshot, represent a single day
1.4.3
1.5.3
1.6.3
1.7.3
However, given the restrictions on the overall design, a typical formula would return 4 days.
The closest formula that partially works for me, is as follows.
=IFERROR(1/SUM(IF(COUNTIFS($E$8:$E$2000,$E$8:$E$2000, $B$8:$B$2000,"Commissioning")=1,1,0)),0)
I have tried pivot tables, however they don't quite work for me, and they add a great overhead to the document.
Thank you in advance for any support.
Regards,
Alain

Averaging production percentages (Hourly) based on different values for a total for the day?

I'm trying to add a daily average of the hours used vs the items completed. The problem is, some items are done by how many there are to do (e.g. 5 EA) and some are based on feet to install (e.g. 100 FT). Here is the link to an image that should help to clarify what my post doesn't say well.
I'm not sure how to best accomplish the above with a formula I can use within "Conditional Formatting" to highlight the cells in green, yellow, or red based on the day's totals.
Below is the formula that I have attempted to use to achieve my goal but I have a feelings that it is wrong as the results don't seem to add up to me (in F:41, I feel that that should at least be yellow and not red). I'm sure that I am missing something simple, but I just don't know what it could be.
=F41/(SUMPRODUCT($G$18:$G$38,$X$18:$X$38)/($X$18:$X$38))>0.95
=F41/(SUMPRODUCT($G$18:$G$38,$X$18:$X$38)/($X$18:$X$38))>=0.9
=F41/(SUMPRODUCT($G$18:$G$38,$X$18:$X$38)/($X$18:$X$38))<0.9
As my formula above says, I'm trying to color based on the value being greater than or less than a certain percentage. The colors are explained in the image attached.
I'm honestly at a loss as to the best way to handle this, and it may be that I am over thinking it honestly. I've been known to do that on more than one occasion.
Note: The hours are not all worked in one day, but I was testing a variety of cells to make sure my formula carried correctly. Hours are based on (2) people working an 8 hour day for a total of 16 hours per day (hence the odd look there).
The formula below is what ended up working. It took a bit of time, but I did get it working.
=SUMPRODUCT(G18:G38,1/X18:X38)/F41>0.95
=SUMPRODUCT(G18:G38,1/X18:X38)/F41>=0.9
=SUMPRODUCT(G18:G38,1/X18:X38)/F41<0.9

duplicating count or only looking for 1st statement

Link to sample spreadsheet: attendance tracking
The tab to look at is the AM Classes. We need a count of how many students attended a class/group that day but it must be unduplicated. Such as some students may attend more than one STEM class in a day, but how many they attend in one day doesn't matter. We only need it to count the student once for that day in the STEM group. What I have is two different options (G1027 & M1027) but they aren't working correctly. I hope this is making sense. Attendance will be entered in using set codes (different letters of the alphabet- A1027 shows the codes.) What we need to track and their codes are in column C at the bottom (the blue lines.) I was also given the suggestion of having the formula look through the cells in that days column and find anyone of those codes and if it did, to use another column that is filled with 1's to do the actual counting (Column F). I'm not sure how to set that up though.
Thank you so much for looking at this. We have struggled with this for a while now and have had it on google forums and no suggestions on how to fix it. Below is a snapshot showing a section of the sample sheet and what we are struggling with. Thanks again.
screenshot
Try G1027:
=SUMPRODUCT(REGEXMATCH(G4:G1016,"(?i)[aglmpst]"))

Calculating Multiple Averages

It's my first time posting a question to this forum. Though I have found answers here many times before, I have been unable to find a solution to my current predicament.
I work in a call center and each week I need to analyze data from the thousands of call that took place over the week. I'm new to programming in Excel-VBA but I've been able to get pretty far.
The data is produced by a third party program and the format is nigh unreadable. Much of the programming I've done so far has been geared towards making the data more organized. Now, I'd like to get into more analysis.
The data is arranged by employee number (NOT in order, though). Each employee takes several calls over the course of the week, some for which the customer takes a survey. It's the survey scores I want. I want to take the average of all the surveys for each employee and then display that average in the same row as each of the entries.
Example
The yellow highlighted area is what I want to add. Any ideas? Thanks for any help in advance!
No need for VBA. If you have the supported version of Excel you can use AVERAGEIF. If not you can use below formula.
Enter as an array formula by pressing Ctrl+Shift+Enter when exiting cell edit mode (instead of just enter).
=AVERAGE(IF($A$2:$A$13=A2,$B$2:$B$13))
Then copy down for all rows.

Calculate "cell/sum(cells)" script across hundreds of small sets

I'm new here, and would greatly appreciate some help with this problem. I'm trying to take a column (Column H in this case) that's split up by blank rows into a few hundred sets of 21 cells each and find the portion of each cell to that set.
Picture - Objective: Take a cell and divide it against 21 other cells in that set. Skip the blank row and repeat the same process several hundred times.
For example, I want to find out: "In 2015, what portion of Alabama employees were in Management Occupations?" and come to the conclusion that 3.669% were in management (Solution example would be cell [I3]). I want to calculate that for all states across all occupations across all years.
I am currently doing this by typing out what's found in column K to get the solutions found in column I, but that is very laborious and seems inefficient. How would I go about getting solutions found in Column I in the easiest way possible?
Please note that the groups must be broken up by state, which is why there are blank rows between each state.
Thank you very much, and if you need a further explanation of what I'm trying to accomplish, please let me know and I'll respond immediately!
Use SUMIF():
=H3/SUMIF(C:C,C3,H:H)
It will now group the it by the state.
If you want to group it further then use SUMIFS():
=H3/SUMIFS(H:H,C:C,C3,A:A,2015)
This will group it by the state and year 2015.

Resources