Skip to content

Commit 6fa8700

Browse files
committed
Pep8 fixes
1 parent 7d68fb9 commit 6fa8700

File tree

1 file changed

+12
-5
lines changed

1 file changed

+12
-5
lines changed

openfisca_aotearoa/variables/kiwisaver.py

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,23 @@
66
from openfisca_aotearoa.entities import Titled_Property, Person
77
from numpy import clip
88

9-
#All variables are according to the reference link http://www.legislation.govt.nz/act/public/2006/0040/latest/DLM379487.html#DLM379487
9+
# All variables are according to the reference link http://www.legislation.govt.nz/act/public/2006/0040/latest/DLM379487.html#DLM379487
10+
1011

1112
class ks_duration(Variable):
1213
value_type = int
1314
entity = Person
1415
definition_period = MONTH
1516
label = u"Years the prospective home buyer has been a member of a kiwisaver account"
1617

18+
1719
class contrib_duration__kiwisaver(Variable):
1820
value_type = int
1921
entity = Person
2022
definition_period = MONTH
2123
label = u"Years the prospective home buyer has been contributing continuously to their kiwisaver account"
2224

25+
2326
class contrib_duration__kiwisaver(Variable):
2427
value_type = bool
2528
entity = Person
@@ -29,15 +32,17 @@ class contrib_duration__kiwisaver(Variable):
2932
def formula(persons, period):
3033
return persons('ks_contrib_duration', period) >= 3
3134

35+
3236
class homestart_grant__kiwisaver(Variable):
3337
value_type = float
3438
entity = Person
3539
definition_period = MONTH
3640
label = u"Amount available to you from the Homestart grant"
3741

3842
def formula(persons, period):
39-
HS_grant = persons('ks_contrib_duration', period) * persons('ks_contrib_duration_satisfied', period) * 1000
40-
return clip(HS_grant,0,5000)
43+
HS_grant = persons('ks_contrib_duration', period) * \
44+
persons('ks_contrib_duration_satisfied', period) * 1000
45+
return clip(HS_grant, 0, 5000)
4146

4247

4348
class purc_price(Variable):
@@ -110,7 +115,7 @@ class homestart_deposit_eligible(Variable):
110115

111116
def formula(persons, period):
112117
return persons('total_savings__kiwisaver', period) >= persons('homestart_deposit_req__kiwisaver', period)
113-
118+
114119

115120
class lvr_deposit_eligible(Variable):
116121
value_type = float
@@ -129,10 +134,12 @@ class indv_income_per_hs_grant(Variable):
129134
set_input = set_input_divide_by_period
130135
# Check how to set input by user and check against the threshold
131136

137+
132138
class combined_income_per_hs_grant(Variable):
133139
value_type = int
134140
entity = Person
135141
definition_period = YEAR
136-
set_input = set_input_divide_by_period # Allows user to declare a salary for a year.
142+
# Allows user to declare a salary for a year.
143+
set_input = set_input_divide_by_period
137144
# Check how to set input by user and check against the threshold
138145
label = "Combined income"

0 commit comments

Comments
 (0)