---------------------------------------------------------------------------------------------------------------------------------- name: log: C:\Users\rwr\Dropbox\basu-house\build\code\../temp/regis_barnichon.log log type: text opened on: 17 Jul 2016, 12:11:55 . /*** FRED data to create tightness ***/ > /*** Unemployment Level > 2015-10: 7,908 Thousands of Persons (+ see more) > Monthly, Seasonally Adjusted, UNEMPLOY, Updated: 2015-11-06 7:51 AM CST > > Job Openings: Total Nonfarm > 2015-09: 3.7 Rate (+ see more) > Monthly, Seasonally Adjusted, JTSJOR, Updated: 2015-11-12 9:16 AM CST > > Job Openings: Total Nonfarm > 2015-09: 5,526 Level in Thousands (+ see more) > Monthly, Seasonally Adjusted, JTSJOL, Updated: 2015-11-12 9:16 AM CST > ***/ > freduse UNEMPLOY JTSJOL, clear; (822 observations read) (186 observations read) . gen datem = mofd(daten); . format datem %tm; . rename UNEMPLOY unempl; . rename JTSJOL v; . keep datem unempl v; . save `tempdata'`prg'_temp, replace; (note: file ../temp/regis_barnichon_temp.dta not found) file ../temp/regis_barnichon_temp.dta saved . /*** COPY DATA FROM BARNICHON'S WEBSITE ***/ > copy "https://sites.google.com/site/regisbarnichon/cv/HWI_index.txt?attredirects=0" `tempdata'`prg'.txt, replace; . import delimited `tempdata'`prg'.txt, rowrange(7:) varnames(6) clear; (2 vars, 768 obs) . gen year = substr(date,1,4); . destring year, replace; year has all characters numeric; replaced as int . gen month = substr(date,6,2); . destring month, replace; month has all characters numeric; replaced as byte . gen datem = ym(year,month); . tsset datem, monthly; time variable: datem, 1951m1 to 2014m12 delta: 1 month . /*** merge in FRED data ***/ > merge 1:1 datem using `tempdata'`prg'_temp, keep(match) assert(match using) nogen; Result # of obs. ----------------------------------------- not matched 0 matched 768 ----------------------------------------- . erase `tempdata'`prg'_temp.dta; . /* normalize to 2014m1 */ > rename compositehwi hwi; . gen tempa = v if datem == ym(2014,1); (767 missing values generated) . egen tempb = max(tempa); . gen temp1 = hwi if datem == ym(2014,1); (767 missing values generated) . egen temp2 = max(temp1); . gen vacancies = tempb*hwi/temp2; . drop temp1 temp2 tempa tempb; . tsline vacancies; . gen tightness = vacancies / unempl; . tsline tightness, lc(black) lw(0.8) > xtitle("") ytitle("Tightness") ylabel(, angle(h) grid) > plotregion(lstyle(none)) yscale(noline) > tlabel(1955m1(60)2010m1, format(%tm_YY)); . /* tsline compositehwi; */ > > keep datem tightness; . save `output'`prg'_data, replace; (note: file ../output/regis_barnichon_data.dta not found) file ../output/regis_barnichon_data.dta saved . log close; name: log: C:\Users\rwr\Dropbox\basu-house\build\code\../temp/regis_barnichon.log log type: text closed on: 17 Jul 2016, 12:11:57 ----------------------------------------------------------------------------------------------------------------------------------