fastest_goal: Fastest goal total amount

Description Usage Arguments Details Value

View source: R/model_portfolio.R

Description

How quickly can you reach the goal total amount, given a starting amount, maximum annual contribution, current age, and goal annual amount.

Usage

1
2
3
4
5
6
7
8
fastest_goal(
  principle,
  maximum_contribution,
  age,
  goal_annual_amount,
  constant = 1.01,
  return_rate = 0.05
)

Arguments

principle

The initial total amount

maximum_contribution

The maximum annual contribution possible

age

Your current age

goal_annual_amount

The goal annual amount to withdraw in retirement

constant

Optional constant to reduce short-term returns. Default determined from experimentation.

return_rate

Optional long term rate of return. Default determined from experimentation.

Details

Numerical approximation using Newton's method. https://math.stackexchange.com/questions/925838/constructing-a-while-loop-in-r-for-newtons-method

Value

A number of years until growth and contributions reaches goal growth


eanway/finance documentation built on Feb. 28, 2021, 4:56 p.m.