Replication of Mendoza 1995 Model

Hello there!
I am currently trying to replicate Mendoza 1995 “The terms of trade, the real exchange rate, and ecnomic fluctuations” using the inelastic interest rate to close the model intead of the endogenous discount factor. In the original paper, the input factors hx (labor for the exportable sector), hf (labor for the importable sector), and kn (capital for the non-tradable sector) are stated to be “supplied inelastically.” Consequently, I have considered them as parameters within my model. I am not sure if this is the correct approach and I need help. I am attaching the mod file and the original paper.

In addition, leisure is defined as: L = T - hx - hf - hn, where T is total time available for leisure and labor. I write hx = hf = 0.05, because the paper considers hx/T = hf/T = 0.05 and I take T as 1. However, when i write the model i am not sure if I need to write exp(hx) or just hx in the main equations. Same for T, should I write T as exp(T) (exp(1))?

In general, how can I treat the “variables” of the model when they are “inelastically supplied”? How to write them when i consider the model in logs?

Thank you!

m95.mod (7.7 KB)
mendoza1995 (1).pdf (668.8 KB)
Solver for steady state:
solver.m (1.3 KB)

More than 10 years ago I tried to replicate that paper, but did not get too far. There are a few statements in the paper that are not sufficiently precise to know what exactly was done. For example:

  1. The endogenous discount factor is not homogeneous of degree 1. Hence it is not invariant to rescaling the time endowment T, but no value is provided.
  2. Point (6) of the calibration on page 121 states that the ratio of total trade to GDP was set to 0.87. At the top of page 119 it is stated that GDP is defined consistent with an aggregate production function, using a weighted geometric average of sectoral production functions. This would imply something like
    Y = {\left( {{{\left( {{y^X}} \right)}^a}{{\left( {{y^f}} \right)}^{1 - a}}} \right)^\kappa }{\left( {{y^n}} \right)^{1 - \kappa }}
    where \kappa would be the share of traded sector output in total GDP. But this is never clarified.
  3. If the aforementioned definition is correct, output is not measured in import prices. So was a “GDP deflator” defined from the expenditure function used as was done for the CPI? That is, when the ratio of total trade to GDP is set, is this total trade at import prices relative to GDP in import prices?
    Using expenditure minimization, the corresponding GDP deflator to obtain GDP at import prices would then be
    {p^Y} = \left( {{{\left( {\frac{{{p^X}}}{{\kappa \alpha }}} \right)}^{\kappa \alpha }}{{\left( {\frac{1}{{\kappa \left( {1 - \alpha } \right)}}} \right)}^{\kappa \left( {1 - \alpha } \right)}}{{\left( {\frac{{{p^N}}}{{\left( {1 - \kappa } \right)}}} \right)}^{1 - \kappa }}} \right)
  4. The expenditure share between tradables and non-tradables is set to 0.87. But is this
    \Omega = \frac{{{p^N}{c^N}}}{{{p^T}{c^T}}} = 0.87
    or
    \Omega = \frac{{{c^N}}}{{{c^T}}} = 0.87
    The former would be consistent with the notion of expenditure as price times quantity, while taking the ratio of the quantities is what subsequent papers based on this work do.
  5. For developing countries, the paper says on page 122 that “TT/Y is less than ½ on average”. But what is the exact value used? 0.5?

Unfortunately, the original codes have been lost, so there may not be a way to know.

I am attaching how far I got the last time:
Mendoza1995.mod (4.2 KB)
Mendoza1995_steadystate.m (8.7 KB)

1 Like

Hi Professor,

I just wanted to say thank you for sharing the files with me. I really appreciate it, and I’m confident that they will be incredibly helpful for my project.

Based on what you mentioned, my original plan was to use the Mendoza model to qualitatively replicate the results of Mendoza (1995). Specifically, I want to explore the effects of terms of trade on business cycles by incorporating elastic interest rate debt into the model. I was wondering if you have any recommendations on how I can achieve this successfully, or if you think I should consider using a different model altogether?

I value your expertise and guidance, and any insights you can provide would be greatly appreciated.

Thanks again for your support!

I think you can try to get as close as possible to the model results, but you should not expect to exactly match them.

Hello Professor,

I hope this message finds you well. After making some small adjustments, I was able to find the steady state. As far as I understand, the main issue is the calibration of K_N, which resulted in a negative value of C_N in the steady state. As a consequence, the steady state computes imaginary numbers for c_ss and lambda_ss.

To address this problem, I adjusted the value of K_N to a very small value, say 0.5, which allowed me to resolve the issue and proceed with the steady state computation.

Here’s a summary of the changes I made:

In the Mendoza1995.mod file:

  • In equation 28, line (146):
    y = (y_X^alppha * y_M^(1-alppha))^kappa * (Q * (T - l - L_X - L_M)^alpha_N * K_N^(1-alpha_N))^(1-kappa);
    I made sure that this definition is consistent with the output definition considered in the steady state.

  • In equation 29, line (149):
    interest_differential = p_c(+1) / p_c * (1 + r_star) - (1 + r_star);
    I ensured that this definition is consistent with interest_differential = 0 in the steady state.

In the Mendoza1995_steadystate.m file:

  • K_N = 0.5 in line (145);
    I set the value of K_N to 0.5 to facilitate the steady state computation and match the IRFS of the P_X shock

  • d = (p_X * (y_X - c_X) + (y_M - c_M) - invest) / (-r_star);
    I ensured that there are no residuals in the static equations, given the modification I made to K_N.

I would like to seek your input on whether these changes are appropriate to get as close as possible to the model results. If you have any suggestions on how to further improve the approach, I would greatly appreciate your guidance.

Thank you very much for your time and support!

Mendoza1995_steadystate.m (8.7 KB)
Mendoza1995.mod (4.2 KB)

Yes, that sounds sensible. The interest_differential was an obvious typo, while the consistent output definition got lost over time when I did not reset the file to its last state.