Warning message when using KFTT

Hi Robert,

When I use KFTT method for discretization, I got this message:

Warning: discretizeLifeCycleAR1_KFTT: failed to hit four moments in more than 20% of conditional distributions
In discretizeLifeCycleAR1_KFTT (line 367)

How will it affect the results & should I change to 3 moments?

Also I think there are some typos in TransitionPath_Case1_FHorz.m. If I use KFTT method and set n_z=5, it generates z_grid_J, size 5*J. But TransitionPath_Case1_FHorz use N_z=prod(n_z) in line 245 and then use it to check the size of inputs.

Error using TransitionPath_Case1_FHorz (line 258)
z_grid is not the correct shape (should be of size N_z-by-1) \n

2 Likes

Because it is just an AR(1) with normal innovations, the first two conditional moments are the important ones [the first two moments on the normal innovations] so the fact it is missing the fourth moment in many of them not very important.

I will look into the trans path soon and get back to you.

PS. If you really cared about the third and fourth moments, you wouldn’t use a normal distribution :wink:
PPS. Normal distributions are fully defined by their first two moments, all higher moments are just functions of the first two. [This is not 100% relevant, just mentioning.]
PPPS. You can look at otheroutputs.nMoments_grid. It shows how many moments were matched from each grid point (for the conditional distribution), and presumably they are still all hitting 2+. The way the code works, it first tries hitting 4 moments, if this fails it tries hitting 3, if this fails it tries hitting 2, if this fails it tries hitting 1. So lot’s of failing 4 probably still means mostly hitting 2-3.

2 Likes

Transition path should be fixed to handle age-dependent exogenous markovs. I don’t have an example code handy that actually uses this aspect, so let me know if it still doesn’t work.

1 Like