dcegm.law_of_motion¶
Functions¶
|
|
|
The function adds a vmap layer for a specific grid. |
|
|
|
|
Simulation. |
|
Simulation. |
Module Contents¶
- dcegm.law_of_motion.calc_cont_grids_next_period(params, income_shock_draws_unscaled, model_structure, model_config, model_funcs)¶
- dcegm.law_of_motion.add_vmap_chain_for_grid(inner_func, gname)¶
The function adds a vmap layer for a specific grid.
It vmaps over the remaining dimension of the grid. So if we have a grid that is (n_discrete_states, n_grid_points), we can later vmap over the discrete states and this function will add the n_grid_points dimension to be vmapped over. The function only expects later the grid to arrive in n_grid_points. So we can also use the function in the final period calculation.
- dcegm.law_of_motion.calc_beginning_of_period_assets_for_single_state(state_vec, asset_end_of_previous_period, income_shock_draw, params, compute_assets_begin_of_period, aux_outs)¶
- dcegm.law_of_motion.calc_assets_beginning_of_period_2cont_vec(state_vec, continuous_state_beginning_of_period, asset_end_of_previous_period, income_shock_draw, params, compute_assets_begin_of_period, aux_outs)¶
- dcegm.law_of_motion.calculate_continuous_state(discrete_states_beginning_of_period, continuous_grid, params, compute_continuous_state)¶
- dcegm.law_of_motion.calc_continuous_state_for_each_grid_point(state_vec, exog_continuous_grid_point, params, compute_continuous_state)¶
- dcegm.law_of_motion.calculate_assets_begin_of_period_for_all_agents(states_beginning_of_period, asset_grid_point_end_of_previous_period, income_shocks_of_period, params, compute_assets_begin_of_period)¶
Simulation.
- dcegm.law_of_motion.calculate_second_continuous_state_for_all_agents(discrete_states_beginning_of_period, continuous_state_beginning_of_period, params, compute_continuous_state)¶
Simulation.