ENH: Rounding and harmonization in dates
TeBackh opened this issue · 0 comments
Is your feature request related to a problem?
Currently we partly use in part decimal representations of birthdate_decimal
and also age_of_retirement
, and use seperate variables geburtsjahr
and geburtsmonat
in other places. This should be harmonized.
Can you please make a note somewhere that we should decide to either use year - month in separate variables throughout (like here) or make single variables out of it (like
birthdate_decimal
) ? There are arguments for both; I think there are few arguments for mixing.
Originally posted by @hmgaudecker in #634 (comment)
Discussion:
Using decimal representations, reduces programming lines in several functions and allows for jax-compatibility without writing excessively long code lines.
However, decimal representation may cause imprecisions due to rounding and hence interfer with (in)equality constraints.
Describe the solution you would like to see
It would be good to be able to implement some leniency in (in)equality constraints to be able to use decimal representations everywhere.
E.g. here
if rentner and ges_rente_vorauss_regelrente:
# Early retirement (before full retirement age): Zugangsfaktor < 1
if age_of_retirement < _ges_rente_altersgrenze_abschlagsfrei: # [ERA,FRA)