ConsLaborModel¶
Subclasses of AgentType representing consumers who make decisions about how much labor to supply, as well as a consumptionsaving decision.
It currently only has one model: labor supply on the intensive margin (unit interval) with CRRA utility from a composite good (of consumption and leisure), with transitory and permanent productivity shocks. Agents choose their quantities of labor and consumption after observing both of these shocks, so the transitory shock is a state variable.

class
HARK.ConsumptionSaving.ConsLaborModel.
ConsumerLaborSolution
(cFunc=None, LbrFunc=None, vFunc=None, vPfunc=None, bNrmMin=None)¶ Bases:
HARK.core.MetricObject
A class for representing one period of the solution to a Consumer Labor problem.
Parameters:  cFunc (function) – The consumption function for this period, defined over normalized bank balances and the transitory productivity shock: cNrm = cFunc(bNrm,TranShk).
 LbrFunc (function) – The labor supply function for this period, defined over normalized bank balances 0.751784276198: Lbr = LbrFunc(bNrm,TranShk).
 vFunc (function) – The beginningofperiod value function for this period, defined over normalized bank balances 0.751784276198: v = vFunc(bNrm,TranShk).
 vPfunc (function) – The beginningofperiod marginal value (of bank balances) function for this period, defined over normalized bank balances 0.751784276198: vP = vPfunc(bNrm,TranShk).
 bNrmMin (float) – The minimum allowable bank balances for this period, as a function of the transitory shock. cFunc, LbrFunc, etc are undefined for bNrm < bNrmMin(TranShk).

distance_criteria
= ['cFunc', 'LbrFunc']¶

class
HARK.ConsumptionSaving.ConsLaborModel.
LaborIntMargConsumerType
(**kwds)¶ Bases:
HARK.ConsumptionSaving.ConsIndShockModel.IndShockConsumerType
A class representing agents who make a decision each period about how much to consume vs save and how much labor to supply (as a fraction of their time). They get CRRA utility from a composite good x_t = c_t*z_t^alpha, and discount future utility flows at a constant factor.
See init_labor_intensive for a dictionary of the keywords that should be passed to the constructor. Same parameters as AgentType.

calc_bounding_values
()¶ Calculate human wealth plus minimum and maximum MPC in an infinite horizon model with only one period repeated indefinitely. Store results as attributes of self. Human wealth is the present discounted value of expected future income after receiving income this period, ignoring mort ality. The maximum MPC is the limit of the MPC as m –> mNrmMin. The minimum MPC is the limit of the MPC as m –> infty.
NOT YET IMPLEMENTED FOR THIS CLASS
Parameters: None – Returns: Return type: None

get_controls
()¶ Calculates consumption and labor supply for each consumer of this type using the consumption and labor functions in each period of the cycle.
Parameters: None – Returns: Return type: None

get_poststates
()¶ Calculates endofperiod assets for each consumer of this type.
Parameters: None – Returns: Return type: None

get_states
()¶ Calculates updated values of normalized bank balances and permanent income level for each agent. Uses pLvlNow, aNrmNow, PermShkNow. Calls the get_states method for the parent class, then erases mNrmNow, which cannot be calculated until after get_controls in this model.
Parameters: None – Returns: Return type: None

make_euler_error_func
(mMax=100, approx_inc_dstn=True)¶ Creates a “normalized Euler error” function for this instance, mapping from market resources to “consumption error per dollar of consumption.” Stores result in attribute eulerErrorFunc as an interpolated function. Has option to use approximate income distribution stored in self.IncShkDstn or to use a (temporary) very dense approximation.
NOT YET IMPLEMENTED FOR THIS CLASS
Parameters:  mMax (float) – Maximum normalized market resources for the Euler error function.
 approx_inc_dstn (Boolean) – Indicator for whether to use the approximate discrete income distri bution stored in self.IncShkDstn[0], or to use a very accurate discrete approximation instead. When True, uses approximation in IncShkDstn; when False, makes and uses a very dense approximation.
Returns: Return type: Notes
This method is not used by any other code in the library. Rather, it is here for expository and benchmarking purposes.

plot_LbrFunc
(t, bMin=None, bMax=None, ShkSet=None)¶ Plot the labor supply function by bank balances at a given set of transitory shocks.
Parameters:  t (int) – Time index of the solution for which to plot the labor supply function.
 bMin (float or None) – Minimum value of bNrm at which to begin the plot. If None, defaults to the minimum allowable value of bNrm for each transitory shock.
 bMax (float or None) – Maximum value of bNrm at which to end the plot. If None, defaults to bMin + 20.
 ShkSet ([float] or None) – Array or list of transitory shocks at which to plot the labor supply function. If None, defaults to the TranShkGrid for this time period.
Returns: Return type:

plot_cFunc
(t, bMin=None, bMax=None, ShkSet=None)¶ Plot the consumption function by bank balances at a given set of transitory shocks.
Parameters:  t (int) – Time index of the solution for which to plot the consumption function.
 bMin (float or None) – Minimum value of bNrm at which to begin the plot. If None, defaults to the minimum allowable value of bNrm for each transitory shock.
 bMax (float or None) – Maximum value of bNrm at which to end the plot. If None, defaults to bMin + 20.
 ShkSet ([float] or None) – Array or list of transitory shocks at which to plot the consumption function. If None, defaults to the TranShkGrid for this time period.
Returns: Return type:

time_inv_
= ['CRRA', 'Rfree', 'DiscFac', 'BoroCnstArt', 'BoroCnstArt', 'vFuncBool', 'CubicBool']¶

time_vary_
= ['LivPrb', 'PermGroFac', 'WageRte']¶

update
()¶ Update the income process, the assets grid, and the terminal solution.
Parameters: None – Returns: Return type: None

update_LbrCost
()¶ Construct the agevarying cost of working LbrCost using the attribute LbrCostCoeffs. This attribute should be a 1D array of arbitrary length, representing polynomial coefficients (over t_cycle) for (log) LbrCost.
Parameters: None – Returns: Return type: None

update_TranShkGrid
()¶ Create a timevarying list of arrays for TranShkGrid using TranShkDstn, which is created by the method update_income_process(). Simply takes the transitory shock values and uses them as a state grid; can be improved. Creates the attribute TranShkGrid.
Parameters: None – Returns: Return type: None


HARK.ConsumptionSaving.ConsLaborModel.
solve_ConsLaborIntMarg
(solution_next, PermShkDstn, TranShkDstn, LivPrb, DiscFac, CRRA, Rfree, PermGroFac, BoroCnstArt, aXtraGrid, TranShkGrid, vFuncBool, CubicBool, WageRte, LbrCost)¶ Solves one period of the consumptionsaving model with endogenous labor supply on the intensive margin by using the endogenous grid method to invert the first order conditions for optimal composite consumption and between consumption and leisure, obviating any search for optimal controls.
Parameters:  solution_next (ConsumerLaborSolution) – The solution to the next period’s problem; must have the attributes vPfunc and bNrmMinFunc representing marginal value of bank balances and minimum (normalized) bank balances as a function of the transitory shock.
 PermShkDstn ([np.array]) – Discrete distribution of permanent productivity shocks.
 TranShkDstn ([np.array]) – Discrete distribution of transitory productivity shocks.
 LivPrb (float) – Survival probability; likelihood of being alive at the beginning of the succeeding period.
 DiscFac (float) – Intertemporal discount factor.
 CRRA (float) – Coefficient of relative risk aversion over the composite good.
 Rfree (float) – Risk free interest rate on assets retained at the end of the period.
 PermGroFac (float) – Expected permanent income growth factor for next period.
 BoroCnstArt (float or None) – Borrowing constraint for the minimum allowable assets to end the period with. Currently not handled, must be None.
 aXtraGrid (np.array) – Array of “extra” endofperiod asset values– assets above the absolute minimum acceptable level.
 TranShkGrid (np.array) – Grid of transitory shock values to use as a state grid for interpolation.
 vFuncBool (boolean) – An indicator for whether the value function should be computed and included in the reported solution. Not yet handled, must be False.
 CubicBool (boolean) – An indicator for whether the solver should use cubic or linear interpolation. Cubic interpolation is not yet handled, must be False.
 WageRte (float) – Wage rate per unit of labor supplied.
 LbrCost (float) – Cost parameter for supplying labor: u_t = U(x_t), x_t = c_t*z_t^LbrCost, where z_t is leisure = 1  Lbr_t.
Returns: solution_now – The solution to this period’s problem, including a consumption function cFunc, a labor supply function LbrFunc, and a marginal value function vPfunc; each are defined over normalized bank balances and transitory prod shock. Also includes bNrmMinNow, the minimum permissible bank balances as a function of the transitory productivity shock.
Return type: