Skip to content

Commit

Permalink
small correction from Peter Walke
Browse files Browse the repository at this point in the history
  • Loading branch information
ulno committed Apr 11, 2022
1 parent 9405595 commit b69f5f5
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions ggia_app/consumption.py
Original file line number Diff line number Diff line change
Expand Up @@ -412,9 +412,14 @@ def __init__(self, year, country, pop_size,
# Otherwise, the user selects the income level of the household (they choose by quintiles)
if income_choice > len(INCOME_CHOICE_TO_HOUSEHOLD) or income_choice<0:
income_choice = 0
self.income_choice = INCOME_CHOICE_TO_HOUSEHOLD[income_choice]
income_scaler = INCOME_SCALING_T.loc[self.income_choice, country] \
/ INCOME_SCALING_T.loc['Total_household', country] # USER_INPUT
self.income_choice = income_choice
if self.income_choice < DELTA_ZERO:
income_scaler = 1
else:
self.income_choice = INCOME_CHOICE_TO_HOUSEHOLD[income_choice]
income_scaler = INCOME_SCALING_T.loc[self.income_choice, country] \
/ INCOME_SCALING_T.loc['Total_household', country] # USER_INPUT

elasticity = 1 # Random number for now. It should be specific to country and product
# TODO: do later

Expand Down

0 comments on commit b69f5f5

Please sign in to comment.