Learn R Programming

stanette (version 2.21.4)

gofplot: Overall goodness-of-fit plots.

Description

Provides a convenient and fast way to implement three commonly used goodness-of-fit plotting over the whole population across the input data.

Usage

gofplot(fit)

Arguments

fit

a PMXStanFit object.

Value

No return value, called for side effects

Details

This function is a generic version covering three methods for the PMXStanFit class: plot.gof.pred.obs(), plot.gof.pred.rsd(), and plot.gof.idv(). They plot medians of predictions vs. observations, the differences between medians of predicion and observations vs. predictions, and time profiles of the prediction medians and 95 of observations, repectively.

See Also

PMXStanFit for the methods plot.gof.pred.obs(), plot.gof.idv(), and plot.gof.pred.rsd().

Examples

Run this code
# NOT RUN {
m1 <- PMXStanModel(path = tempfile("pk_m1"), pk.struct = "1-cmpt", compile=TRUE)

data("examples_data")
dat <- prepareInputData(data.source = d1_nm_poppk, model = m1)

fit <- PMXStanFit(m1, dat, iter=100, chains=1)

fit$plot.gof.pred.obs()
fit$plot.gof.idv()
fit$plot.gof.pred.rsd()

gofplot(fit)
# }

Run the code above in your browser using DataLab