# termstrc
library(termstrc)
data(eurobonds)
group <- c("GERMANY", "AUSTRIA", "ITALY")
bonddata <- eurobonds
matrange <- c(2,12)
method <- "Nelson/Siegel"
fit <- "prices"
weights <- "duration"
control <- list(eval.max=100000, iter.max=500)
b <- matrix(rep(c(0,0,0, 1),3),nrow=3,byrow=TRUE)
rownames(b) <- group
colnames(b) <- c("beta0","beta1","beta2","tau1")
x <- nelson_estim(group, bonddata, matrange, 
method, fit, weights, startparam=b,control)
print(x)
summary(x)
plot(x)

x$spot$ITALY
x$forward$ITALY
