Difference between revisions of "Template:Inflation"

From Emulation General Wiki
Jump to navigation Jump to search
(Update 2019, add estimate for 2020.)
m (Revise 2021 estimate.)
(One intermediate revision by one other user not shown)
Line 61: Line 61:
 
{{#ifexpr:((2017 >= {{{3}}}) and (2017 < {{{4|{{CURRENTYEAR}}}}}))|* 1.0244258329692818 }}
 
{{#ifexpr:((2017 >= {{{3}}}) and (2017 < {{{4|{{CURRENTYEAR}}}}}))|* 1.0244258329692818 }}
 
{{#ifexpr:((2018 >= {{{3}}}) and (2018 < {{{4|{{CURRENTYEAR}}}}}))|* 1.0181221007526015 }}
 
{{#ifexpr:((2018 >= {{{3}}}) and (2018 < {{{4|{{CURRENTYEAR}}}}}))|* 1.0181221007526015 }}
{{#ifexpr:((2019 >= {{{3}}}) and (2019 < {{{4|{{CURRENTYEAR}}}}}))|* 1.0062 }}
+
{{#ifexpr:((2019 >= {{{3}}}) and (2019 < {{{4|{{CURRENTYEAR}}}}}))|* 1.0123358439630637 }}
 +
{{#ifexpr:((2020 >= {{{3}}}) and (2020 < {{{4|{{CURRENTYEAR}}}}}))|* 1.06 }}
 
}} <!-- End inflation tables -->
 
}} <!-- End inflation tables -->
 
) round {{{r|0}}}}}|[[NaN]]}}|[[NaN]]}} in {{CURRENTYEAR}} money">${{{2}}}</abbr></includeonly><noinclude>
 
) round {{{r|0}}}}}|[[NaN]]}}|[[NaN]]}} in {{CURRENTYEAR}} money">${{{2}}}</abbr></includeonly><noinclude>

Revision as of 02:12, 26 November 2021

Displays a product's price as well as a server-side computation of an inflation-adjusted version in United States Dollars. The data is taken from the World Bank, and can only go as far back as 1959. The output is rounded to the nearest dollar.

Use: {{Inflation|Currency|Value|Year}}

Example: $199 in 1991 {{Inflation|USD|199|1991}} = $199