I had a general question regarding the construction of interaction terms using country and period fixed effects. To illustrate, my data looks as follows (I generated a random variable fin with value 100):
Code:
* Example generated by -dataex-. To install: ssc install dataex clear input str3 countrycode int year float(fin dec1950 dec1960 dec1970 dec1980 dec1990 dec2000 decrecent) "BEL" 1950 100 1 0 0 0 0 0 0 "BEL" 1951 100 1 0 0 0 0 0 0 "BEL" 1952 100 1 0 0 0 0 0 0 "BEL" 1953 100 1 0 0 0 0 0 0 "BEL" 1954 100 1 0 0 0 0 0 0 "BEL" 1955 100 1 0 0 0 0 0 0 "BEL" 1956 100 1 0 0 0 0 0 0 "BEL" 1957 100 1 0 0 0 0 0 0 "BEL" 1958 100 1 0 0 0 0 0 0 "BEL" 1959 100 1 0 0 0 0 0 0 "BEL" 1960 100 0 1 0 0 0 0 0 "BEL" 1961 100 0 1 0 0 0 0 0 "BEL" 1962 100 0 1 0 0 0 0 0 "BEL" 1963 100 0 1 0 0 0 0 0 "BEL" 1964 100 0 1 0 0 0 0 0 "BEL" 1965 100 0 1 0 0 0 0 0 "BEL" 1966 100 0 1 0 0 0 0 0 "BEL" 1967 100 0 1 0 0 0 0 0 "BEL" 1968 100 0 1 0 0 0 0 0 "BEL" 1969 100 0 1 0 0 0 0 0 "BEL" 1970 100 0 0 1 0 0 0 0 "BEL" 1971 100 0 0 1 0 0 0 0 "BEL" 1972 100 0 0 1 0 0 0 0 "BEL" 1973 100 0 0 1 0 0 0 0 "BEL" 1974 100 0 0 1 0 0 0 0 "BEL" 1975 100 0 0 1 0 0 0 0 "BEL" 1976 100 0 0 1 0 0 0 0 "BEL" 1977 100 0 0 1 0 0 0 0 "BEL" 1978 100 0 0 1 0 0 0 0 "BEL" 1979 100 0 0 1 0 0 0 0 "BEL" 1980 100 0 0 0 1 0 0 0 "BEL" 1981 100 0 0 0 1 0 0 0 "BEL" 1982 100 0 0 0 1 0 0 0 "BEL" 1983 100 0 0 0 1 0 0 0 "BEL" 1984 100 0 0 0 1 0 0 0 "BEL" 1985 100 0 0 0 1 0 0 0 "BEL" 1986 100 0 0 0 1 0 0 0 "BEL" 1987 100 0 0 0 1 0 0 0 "BEL" 1988 100 0 0 0 1 0 0 0 "BEL" 1989 100 0 0 0 1 0 0 0 "BEL" 1990 100 0 0 0 0 1 0 0 "BEL" 1991 100 0 0 0 0 1 0 0 "BEL" 1992 100 0 0 0 0 1 0 0 "BEL" 1993 100 0 0 0 0 1 0 0 "BEL" 1994 100 0 0 0 0 1 0 0 "BEL" 1995 100 0 0 0 0 1 0 0 "BEL" 1996 100 0 0 0 0 1 0 0 "BEL" 1997 100 0 0 0 0 1 0 0 "BEL" 1998 100 0 0 0 0 1 0 0 "BEL" 1999 100 0 0 0 0 1 0 0 "BEL" 2000 100 0 0 0 0 0 1 0 "BEL" 2001 100 0 0 0 0 0 1 0 "BEL" 2002 100 0 0 0 0 0 1 0 "BEL" 2003 100 0 0 0 0 0 1 0 "BEL" 2004 100 0 0 0 0 0 1 0 "BEL" 2005 100 0 0 0 0 0 1 0 "BEL" 2006 100 0 0 0 0 0 1 0 "BEL" 2007 100 0 0 0 0 0 1 0 "BEL" 2008 100 0 0 0 0 0 1 0 "BEL" 2009 100 0 0 0 0 0 1 0 "BEL" 2010 100 0 0 0 0 0 0 1 "BEL" 2011 100 0 0 0 0 0 0 1 "BEL" 2012 100 0 0 0 0 0 0 1 "BEL" 2013 100 0 0 0 0 0 0 1 "BEL" 2014 100 0 0 0 0 0 0 1 "BEL" 2015 100 0 0 0 0 0 0 1 "BEL" 2016 100 0 0 0 0 0 0 1 "BEL" 2017 100 0 0 0 0 0 0 1 "BRA" 1950 100 1 0 0 0 0 0 0 "BRA" 1951 100 1 0 0 0 0 0 0 "BRA" 1952 100 1 0 0 0 0 0 0 "BRA" 1953 100 1 0 0 0 0 0 0 "BRA" 1954 100 1 0 0 0 0 0 0 "BRA" 1955 100 1 0 0 0 0 0 0 "BRA" 1956 100 1 0 0 0 0 0 0 "BRA" 1957 100 1 0 0 0 0 0 0 "BRA" 1958 100 1 0 0 0 0 0 0 "BRA" 1959 100 1 0 0 0 0 0 0 "BRA" 1960 100 0 1 0 0 0 0 0 "BRA" 1961 100 0 1 0 0 0 0 0 "BRA" 1962 100 0 1 0 0 0 0 0 "BRA" 1963 100 0 1 0 0 0 0 0 "BRA" 1964 100 0 1 0 0 0 0 0 "BRA" 1965 100 0 1 0 0 0 0 0 "BRA" 1966 100 0 1 0 0 0 0 0 "BRA" 1967 100 0 1 0 0 0 0 0 "BRA" 1968 100 0 1 0 0 0 0 0 "BRA" 1969 100 0 1 0 0 0 0 0 "BRA" 1970 100 0 0 1 0 0 0 0 "BRA" 1971 100 0 0 1 0 0 0 0 "BRA" 1972 100 0 0 1 0 0 0 0 "BRA" 1973 100 0 0 1 0 0 0 0 "BRA" 1974 100 0 0 1 0 0 0 0 "BRA" 1975 100 0 0 1 0 0 0 0 "BRA" 1976 100 0 0 1 0 0 0 0 "BRA" 1977 100 0 0 1 0 0 0 0 "BRA" 1978 100 0 0 1 0 0 0 0 "BRA" 1979 100 0 0 1 0 0 0 0 "BRA" 1980 100 0 0 0 1 0 0 0 "BRA" 1981 100 0 0 0 1 0 0 0 end
Best,
Satya
0 Response to Creating interaction terms of country and period fixed effects
Post a Comment