+ Reply to Thread
Results 1 to 6 of 6

coverage lookup based on date range

  1. #1
    Registered User
    Join Date
    07-11-2020
    Location
    new york
    MS-Off Ver
    2016
    Posts
    3

    Question coverage lookup based on date range

    Hello experts,

    I need your help in writing a lookup formula/array that could satisfy this requirement.

    We have 2 traders in this scenario, first trader - X7 always holds his stocks for period of 7 days and oter trader - Y3 always holds his positions for 3 calender days. for example from sample sheet, X7 bought AAPL on January 1st and sold his position on Jan 7th. He bought another lot of AAPL on Jan 4th and sold after 7 days on 10th Jan. Similarly Trader Y3 bought AAPL on 2nd Jan and sold after 3 days on 4th Jan then bought firstr lot of GOOGL on 3rd Jan till 5th Jun , total of 3 days and so on

    My requirmeent is, i want to check what is the overlap of trader Y3 position within trader X7s postiion. For example Y3 held AAPL between 2nd and 4th Jan, which overlaps 100% in X7's first purchase of AAPL from 1st Jan and 7th Jan and overlaps partially(1 day) with his position between 4th Jan to 10th Jan(4th Jan being common). The FB lot that trader Y3 bought between 21-23rd Jan doesnt overlap in X7 range of 24th-30th Jan and so on

    The overlap requirement is only on one side, ie what percenatge of X7 holdings were also present in Y3 portfolio for same stock during same period, 100% overlap, partial or 0%

    The original list contains more than 10k records so only made a sample here. Please let me know how this can be achieved with excel formulas.

    TIA
    Attached Files Attached Files

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,789

    Re: coverage lookup based on date range

    Welcome to the forum.

    You have forgotten to manually mock up the results you would like to see and where for the sample provided. Please add these and post the workbook again. Thanks.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Registered User
    Join Date
    07-11-2020
    Location
    new york
    MS-Off Ver
    2016
    Posts
    3

    Re: coverage lookup based on date range

    Hi Ali, Thanks for pointing that out

    I have included the mock up results, the values i want to be calculated is one of 3 overlap values - "FULL", "PARTIAL" or "NONE"

    Let me know if it is sufficient
    Attached Files Attached Files

  4. #4
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,557

    Re: coverage lookup based on date range

    The following formula replicates the mocked up results:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Let us know if you have any questions.
    Attached Files Attached Files
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

  5. #5
    Registered User
    Join Date
    07-11-2020
    Location
    new york
    MS-Off Ver
    2016
    Posts
    3

    Re: coverage lookup based on date range

    Thanks JeteMc, That was exactly as i wanted

  6. #6
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,557

    Re: coverage lookup based on date range

    You're Welcome and thank you for the feedback. Please take a moment to mark the thread as 'Solved' using the thread tools menu above your first post. I hope that you have a blessed day.

+ 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. [SOLVED] Calculations based on date range lookup
    By goldfield in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-11-2016, 11:36 AM
  2. lookup value based on date range
    By shcsbaker in forum Excel General
    Replies: 4
    Last Post: 06-11-2014, 01:01 PM
  3. [SOLVED] Lookup start and end value based on date range
    By mishaq in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 02-08-2014, 12:35 PM
  4. [SOLVED] Formula to Lookup value based on date within a date range
    By MHamid in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-26-2013, 02:24 PM
  5. Lookup rate based on vendor and date range
    By June12 in forum Excel General
    Replies: 3
    Last Post: 06-30-2011, 09:21 PM
  6. Multiple lookup based on date range pricing
    By posttoamit in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-18-2011, 05:52 PM
  7. Excel 2007 : Lookup of material price based on date range
    By posttoamit in forum Excel General
    Replies: 1
    Last Post: 02-18-2011, 08:58 AM

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