Skip to content

Commit

Permalink
Ajout fonction get_end_date
Browse files Browse the repository at this point in the history
  • Loading branch information
@ChloeLallemand committed Aug 30, 2021
1 parent 2971c4c commit 0a47abd
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions openfisca_france_data/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -354,3 +354,14 @@ def store_input_data_frame(data_frame = None, collection = None, survey = None,
json_file_path = os.path.join(collections_directory, '{}.json'.format(collection))
log.debug("In collection {} the following surveyx are present: {}".format(collection, openfisca_survey_collection.surveys))
openfisca_survey_collection.dump(json_file_path = json_file_path)

def get_end_date(var_list):
tax_benefit_system = openfisca_france_tax_benefit_system
end_date = dict()
for name, variable in sorted(tax_benefit_system.variables.items()):
if name in var_list:
end_date[name] = variable.end or None
else:
continue
return end_date

0 comments on commit 0a47abd

Please sign in to comment.