Loan Amortization Schedule ERROR

Loan Amortization Schedule

#========================================================#

graphics.off(); rm(list = ls())

#=======================================================

1. Input

#=======================================================
i <- 0.1
A <- 10000

#=======================================================

2. Loan Amortization – Bullet Payment

#=======================================================

df <- data.frame(n = 0:10)
df$B <- df$P <- df$I <- df$PI <- 0
df$B[1] <- A # Balance at origination

for(t in 2:11) {

interest

df$I[t] <- df$B[t–1]*i

principal at maturity

df$P[t] <- ifelse(t==11, A, 0)

remaining balance

df$B[t] <- df$B[t–1] – df$P[t]

payments = principal + interest

df$PI[t] <- df$P[t] + df$I[t]
}
(df.bullet <- df)

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.