econirl.DDCProblem

class econirl.DDCProblem(num_states, num_actions, discount_factor=0.9999, scale_parameter=1.0, num_periods=None, state_dim=None, state_encoder=None)[source]

Bases: object

Specification of a Dynamic Discrete Choice problem.

This dataclass contains the structural parameters that define the decision environment, following the notation in Rust (1987).

Variables:
  • num_states (int) – Number of discrete states |S|

  • num_actions (int) – Number of discrete actions |A|

  • discount_factor (float) – Time discount factor beta in [0, 1)

  • scale_parameter (float) – Logit scale parameter sigma > 0 (extreme value shock scale)

Parameters:
  • num_states (int)

  • num_actions (int)

  • discount_factor (float)

  • scale_parameter (float)

  • num_periods (int | None)

  • state_dim (int | None)

  • state_encoder (Callable | None)

Example

>>> problem = DDCProblem(
...     num_states=90,
...     num_actions=2,
...     discount_factor=0.9999,
...     scale_parameter=1.0
... )
num_states: int
num_actions: int
discount_factor: float = 0.9999
scale_parameter: float = 1.0
num_periods: int | None = None
state_dim: int | None = None
state_encoder: Callable | None = None
__init__(num_states, num_actions, discount_factor=0.9999, scale_parameter=1.0, num_periods=None, state_dim=None, state_encoder=None)
Parameters:
  • num_states (int)

  • num_actions (int)

  • discount_factor (float)

  • scale_parameter (float)

  • num_periods (int | None)

  • state_dim (int | None)

  • state_encoder (Callable | None)

Return type:

None