Meer financiƫle functies

Waardering en analyse van obligaties in Python

Joshua Mayhew

Options Trader

De functie nper()

  • Bepaalt het aantal perioden om PV te laten groeien tot FV
import numpy_financial as npf
?npf.nper
Signature: npf.nper(rate, pmt, pv, fv=0)

Compute the number of periodic payments.

Parameters rate : Rate of interest (per period)
pmt : Payment
pv : Present value
fv : (optional) Future value
Waardering en analyse van obligaties in Python

De functie nper()

  • Hoelang sparen voor USD 7.000 bij USD 270 p/m en 5% p/j, maandelijks samengesteld?
import numpy_financial as npf
npf.nper(rate=0.05/12, pmt=-270, pv=0, fv=7000)
24.67
Waardering en analyse van obligaties in Python

De functie pmt()

  • Bepaalt de betaling om PV te laten groeien tot FV
import numpy_financial as npf
?npf.pmt
Signature: npf.pmt(rate, nper, pv, fv=0)

Compute the payment against loan principal plus interest.

Given: * an interest `rate` compounded once per period, of which there are
* `nper` total
* a present value, `pv` (e.g., an amount borrowed)
* a future value, `fv` (e.g., 0)
Return: the (fixed) periodic payment.
Waardering en analyse van obligaties in Python

De functie pmt()

  • We hebben USD 275.000 geleend tegen 3,5% per jaar, maandelijks samengesteld
  • Welke maandlast om de hypotheek in tien jaar af te lossen?
import numpy_financial as npf
npf.pmt(rate=0.035/12, nper=10*12, pv=275000, fv=0)
-2719.36
Waardering en analyse van obligaties in Python

De functie rate()

  • Bepaalt de rente die nodig is om PV te laten groeien tot FV
import numpy_financial as npf
?npf.rate
Signature: npf.rate(nper, pmt, pv, fv)

Compute the rate of interest per period.

Parameters nper : Number of compounding periods
pmt : Payment
pv : Present value
fv : Future value
Waardering en analyse van obligaties in Python

De functie rate()

  • Welk rendement heb je nodig om over 30 jaar te stoppen met werken?
  • Je spaart USD 1.500 per maand en wilt eindigen met USD 1 miljoen.
  • Aannemen: maandelijkse samengestelde rente.
import numpy_financial as npf
12 * npf.rate(nper=30*12, pmt=-1500, pv=0, fv=1000000)
0.0377
Waardering en analyse van obligaties in Python

Laten we oefenen!

Waardering en analyse van obligaties in Python

Preparing Video For Download...