Exercise Hints & Worked Solutions
Session 2
This companion is meant to be used in stages. Try the exercise first. Open the hint if you need a direction, then compare your work with the detailed solution. The solutions emphasize the reasoning behind each calculation, not only the final number.
On the website, the hints and solutions are collapsed until selected. In the PDF, every hint and solution is printed in full so the document can be read offline or used as a conventional solutions manual.
Exercises and Solutions
Exercise 1: The covariance a factor model implies
Problem. [core, pencil] A one-factor model has three standardized series with loadings \lambda=(0.9,\,0.6,\,0.3)', factor variance 1, and mutually uncorrelated idiosyncratic components. Write the full 3\times3 covariance matrix of the observed series. Compute each series’ common share and each pairwise correlation. Which series is the most valuable witness to the factor, and what, if anything, does series 3 contribute?
Exercise 2: Two witnesses
Problem. [core, pencil] One factor with prior f\sim\mathcal N(0,1) is measured by two standardized series, each with loading \lambda=0.8 and idiosyncratic variance \sigma^2_e=0.36, idiosyncratic components independent. The observed values are x_1=-1.5 and x_2=-0.5. Compute the posterior mean and variance of f, twice: once by Gaussian conditioning on the joint distribution and once by precision weighting. Compare with the posterior after observing only x_1, and explain in words why the second witness pulled the estimate in the direction it did.
Exercise 3: The witness floor
Problem. [core, pencil] N standardized series each measure a factor f\sim\mathcal N(0,1) with loading \lambda and idiosyncratic variance \sigma^2_e. Derive the posterior variance of f when the idiosyncratic components are (a) independent and (b) equicorrelated with correlation \rho_e. Show that in case (b) the posterior variance has a strictly positive limit as N\to\infty, and prove the statement: an unlimited supply of equicorrelated witnesses is worth exactly 1/\rho_e independent ones. Evaluate everything for \lambda=0.8, \sigma^2_e=0.36, \rho_e=0.25.
Exercise 4: Rotation, concretely
Problem. [core, pencil] (a) For a one-factor model, exhibit two loading–factor pairs besides (\Lambda,f_\tau) that generate identical data, and identify what each violates in the normalization \operatorname{Var}(f_\tau)=I, \Lambda'\Lambda diagonal, plus a sign convention. (b) For k=2, show that any pair (\Lambda M^{-1},\,Mf_\tau) with M invertible fits identically, and determine which matrices M survive the full normalization.
Exercise 5: Replicate the P1 extraction
Problem. [core, computational, data] Reproduce the Practicum 1 factor extraction from scratch: pull the four weekly FRED series, transform each to a 52-week log difference with the claims series sign-flipped, standardize on the pre-2020 calibration window, and compute the first principal component of the calibration panel. Verify your weights against the reference build. Then compute each series’ common share with respect to your estimated factor and rank the four series by usefulness. Does the ranking match the weights? Should it?
Exercise 6: State-space fluency
Problem. [core, pencil] Write the full system matrices (T,R,Q,Z,H) for a dynamic factor model with k=2 factors following a VAR(2), AR(1) idiosyncratic components, and N=5 monthly series. Give every matrix’s dimensions and the state dimension. Then, for the one-factor version of the model, explain where the five-weight quarterly aggregation row for GDP enters and exactly which additional states it requires.
Exercise 7: The two-step upgrade
Problem. [core, computational] Implement the two-step estimator on a simulated ragged panel: generate n=200 periods of a one-factor panel with N=4 series, loadings (0.9,0.8,0.6,0.3), factor AR(1) coefficient 0.9, and a ragged edge (the last three observations of series 1 and the last observation of series 2 missing). Step 1: principal components and regressions on the balanced rows. Step 2: Kalman filter and smoother over the full panel with parameters fixed. Add assertions. Where does the smoothed factor differ most from the PCA factor, and which estimate tracks the true factor better?
Exercise 8: Who gets credit for the news?
Problem. [core, pencil] A one-factor nowcast has prior f\sim\mathcal N(0,\,0.5) at the start of a week. Two releases arrive: claims, with loading 0.8 and idiosyncratic variance 0.36, surprises at v_1=-1.0; credit, with loading 0.3 and idiosyncratic variance 0.91, surprises at v_2=+0.5 (both measured against the prior). Compute the factor revision and its release-by-release attribution three ways: jointly, sequentially claims-first, and sequentially credit-first. Verify all three give the same final estimate, and explain why the middle numbers differ.
Exercise 9: Choosing the number of factors
Problem. [data] Implement the Bai and Ng (2002) criterion IC_{p2} and validate it on a simulated panel with a known number of factors before trusting it on real data. Then download the FRED-MD monthly panel (McCracken and Ng, 2016), apply the published transformation codes, standardize, and report the chosen number of factors, the variance shares of the leading components, and an interpretation of factor 2’s largest loadings. [extra] Repeat the criterion on the pre-2020 subsample and compare.
Exercise 10: WEI archaeology
Problem. [data] The published Weekly Economic Index confronted its own version of the standardization trap in 2020. Using Lewis et al. (2022), Lewis et al. (2021), and the Dallas Fed’s WEI documentation, identify what the pandemic did to the index’s estimated relationships and what its maintainers changed in response. Relate each change to the calibration-window logic of the P1 build. Then propose, in one page, the v2 design for the four-series P1 tracker that best imports the lessons.