Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to find the year of included ranges

    Recession ranges are lists below
    local recession1 August 1929 March 1933
    local recession2 May 1937 June 1938
    local recession3 February 1945 October 1945
    local recession4 November 1948 October 1949
    local recession5 July 1953 May 1954
    local recession6 August 1957 April 1958
    local recession7 April 1960 February 1961
    local recession8 December 1969 November 1970
    local recession9 November 1973 March 1975
    local recession10 January 1980 July 1980
    local recession11 July 1981 November 1982
    local recession12 July 1990 March 1991
    local recession13 March 2001 November 2001
    local recession14 December 2007 June 2009
    local recession15 February 2020 April 2020


    I want to find the first recession range number that CEO worked
    If, for example, ID 0001 CEO's start_date is 01mar1999 and end_date is 19sep2001. In this case, the work duration period includes recession 13 ranges. (I want the coding result value=13)
    If, for example ID 0002 CEO's start_date is 01oct2001 and end_date is 11sep2010. In this case, this ceo worked during recession 13, and 14 ranges. and so the the first recession range that ceo experienced is 13 (I want the result value=13)
    if ID 0003 CEO 's start_date is 01mar1979 and end_date is 11sep2000. In this case, this ceo worked during recession 10,11,12 ranges, and I want the result value =10.

    If i have data of each ID's start and end date, how do I find the number of recession ranges that ceo first experienced during the work duration dates?
    Last edited by BB Kim; 20 Feb 2023, 19:09.
Working...
X