Method Deck / finance

Inflation-adjusted value (CPI method)

Converts a dollar amount from one period to another period's dollars using two Consumer Price Index values.

Published for review. The Founder is checking every card himself; anything he strikes comes down the same hour.

Try it

Inputs

Outputs

Steps

  1. adjusted_value = amount * (cpi_end / cpi_start).
  2. Round adjusted_value to 2 decimals (money to cents).

Constants

None.

Sources

Worked example and test vectors

NameInputsAnswer
worked example{"amount":100,"cpi_start":258.811,"cpi_end":314.175}$121.39
test vector: deflating forward to backward period{"amount":500,"cpi_start":314.175,"cpi_end":258.811}$411.89

Published card