data(cancer)
cancer2 <- subset(cancer, grepl("55|60|65|70", Age))
fit <- stan_rw(cancer2, time = Year, group = Age,
iter = 900) # low iter for speed only
x <- apc(fit)
print(x)
plot(x, cumulative = TRUE)
Run the code above in your browser using DataLab