Returns the data used for fitting (or newdata) as a tibble with three
diagnostic columns appended:
.fitted: subject-conditional fitted indifference proportion (clamped to(0, 1))..resid: raw residualy - .fittedon the response scale..std_resid: Pearson (standardized) residual -.residdivided by the per-row response SD. Forfamily = "gaussian"the SD is the constantsigma_e; forfamily = "sltb"it is the delta-method SLT SDsqrt(mu * (1 - mu) / (phi + 1)).
Usage
# S3 method for class 'beezdiscounting_tmb'
augment(x, newdata = NULL, ...)Examples
# \donttest{
dd <- simulate_dd_ip(n_subjects = 20, seed = 1)
fit <- fit_dd_tmb(dd, verbose = 0)
head(augment(fit))
#> # A tibble: 6 × 6
#> id x y .fitted .resid .std_resid
#> <chr> <dbl> <dbl> <dbl> <dbl> <dbl>
#> 1 1 7 0.998 0.953 0.0446 0.777
#> 2 1 30 0.891 0.827 0.0641 0.622
#> 3 1 180 0.570 0.443 0.127 0.939
#> 4 1 365 0.290 0.282 0.00826 0.0674
#> 5 1 730 0.152 0.164 -0.0115 -0.114
#> 6 1 1460 0.145 0.0892 0.0561 0.722
# }
