+ Reply to Thread
Results 1 to 6 of 6

Identifying data by time and day of week

  1. #1
    Registered User
    Join Date
    12-24-2019
    Location
    UK
    MS-Off Ver
    Microsoft 365 business
    Posts
    13

    Identifying data by time and day of week

    Hi,

    If someone could help with the following query it would be greatly appreciated.

    In the attached file you will see data for each half hourly period of a month – the date on the left hand side, and the time period at the top.

    You will notice in the file that I have highlighted both the highest and lowest figures in the data (highlighted in orange and blue respectively).

    All the data needs to be split into 3 categories:
    1. Core (highlighted in green)
    2. Unoccupied (highlighted in dark blue)
    3. Shoulder (highlighted in grey)

    Underneath the data I have created formulas that work out the total data in these time frames.

    However, the key aspect I need help with is that weekend days (Saturdays and Sundays) also need to be classed as unoccupied data.

    If someone could help it would be greatly appreciated.

    Many thanks,

    James
    Attached Files Attached Files

  2. #2
    Forum Expert BMV's Avatar
    Join Date
    01-13-2020
    Location
    St-Petersburg, Russia
    MS-Off Ver
    2013-2016
    Posts
    1,329

    Re: Identifying data by time and day of week

    Please Login or Register  to view this content.
    Attached Files Attached Files

  3. #3
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,623

    Re: Identifying data by time and day of week

    By the way, for D42:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    would be enough.

    (But honestly, I first thought about even more complicated one myself : =SUMPRODUCT(C6:P35*(WEEKDAY(B6:B35,2)<6))+SUMPRODUCT(AU6:AX35*(WEEKDAY(B6:B35,2)<6))+SUMPRODUCT(C6:AX35*(WEEKDAY(B6:B35,2)>=6))
    )


    And final note - lower right corner cells are not empty but contain single space. If such spaces appear in other cells you could expect !ARG# errors with SUMPRODUCT (SUM just skips these cells)
    Best Regards,

    Kaper

  4. #4
    Registered User
    Join Date
    12-24-2019
    Location
    UK
    MS-Off Ver
    Microsoft 365 business
    Posts
    13

    Re: Identifying data by time and day of week

    Hi there,

    Thanks very much for your help. I have a few further queries I hope you could help with.

    I noticed that if the formula range is expanded to include empty cells, we receive an error. Ideally, the formulas would cover the entire data range of a month with 31 days. It could be copied to months that only have, either 28, 29 or 30 days and wouldn’t receive an error.

    Separately, I have attached a further file and highlighted in orange two figures that it would be amazing if these could be worked out using a formula each month.

    Many thanks,

    James
    Attached Files Attached Files

  5. #5
    Forum Expert BMV's Avatar
    Join Date
    01-13-2020
    Location
    St-Petersburg, Russia
    MS-Off Ver
    2013-2016
    Posts
    1,329

    Re: Identifying data by time and day of week

    Then it could be array formulas and IFERROR inside
    Attached Files Attached Files

  6. #6
    Forum Guru Kaper's Avatar
    Join Date
    12-14-2013
    Location
    Warsaw, Poland
    MS-Off Ver
    most often: Office 365 in Windows environment
    Posts
    8,623

    Re: Identifying data by time and day of week

    Hi James,
    What is the point to put space in empty cells?
    Unless there is important reason, empty cells shall be empty.

    If they are empty, then formulas for pink cells (note that the formulas are universal for 28...31 days long months, that's why there is row 36 taken into account) are as easy as:

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by Kaper; 04-26-2020 at 01:52 AM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 1
    Last Post: 03-21-2019, 12:17 PM
  2. Identifying short-term highs and lows on time series data
    By alphageneration in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-27-2018, 12:08 AM
  3. Replies: 11
    Last Post: 12-17-2015, 11:34 AM
  4. Generating List of Week Working days and Identifying Holidays
    By ron2k_1 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 10-29-2009, 02:13 PM
  5. Help in identifying the week number of many dates!
    By rukia in forum Excel General
    Replies: 2
    Last Post: 10-20-2009, 02:36 AM
  6. identifying dates for this week and next
    By martinz in forum Excel General
    Replies: 7
    Last Post: 10-11-2009, 12:07 AM
  7. sorting data by time and day of week
    By shawn in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-24-2006, 05:15 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1