apc {surveil} | R Documentation |
Annual and cumulative percent change
Description
Summarize annual and cumulative percent change in risk
Usage
apc(x)
## S3 method for class 'surveil'
apc(x)
## S3 method for class 'stand_surveil'
apc(x)
Arguments
x |
A fitted |
Value
An apc
(list) object containing the following data frames:
- apc
A data frame containing a summary of the posterior distribution for period-specific percent change. This contains the posterior mean (
apc
) 95 percent credible intervals (lwr
andupr
bounds).- cpc
A data frame containing a summary of the posterior distribution for the cumulative percent change in risk at each time period. This contains the posterior mean (
cpc
) and 95 percent credible interval (lwr
andupr
bounds).- apc_samples
MCMC samples from the posterior distribution for period percent change
- cpc_samples
MCMC samples from the posterior distribution for cumulative percent change
See Also
plot.apc
print.apc
stan_rw
standardize
Examples
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)