Difference between the observed efficient release and the smoothed estimate of the latent efficient value. These are measurement residuals of the release used as the model's target, not one-step-ahead prediction errors.
Usage
# S3 method for class 'kk_model'
residuals(object, ...)See also
Other revision nowcasting:
coef.jvn_model(),
coef.kk_model(),
fitted.jvn_model(),
fitted.kk_model(),
jvn_nowcast(),
kk_nowcast(),
logLik.jvn_model(),
logLik.kk_model(),
nobs.jvn_model(),
nobs.kk_model(),
plot.jvn_model(),
plot.kk_model(),
predict.jvn_model(),
predict.kk_model(),
print.jvn_model(),
print.kk_model(),
residuals.jvn_model(),
states(),
summary.jvn_model(),
summary.kk_model(),
vcov.jvn_model(),
vcov.kk_model()
Examples
df <- get_nth_release(
tsbox::ts_span(
tsbox::ts_pc(dplyr::filter(reviser::gdp, id == "US")),
start = "1980-01-01"
),
n = 0:1
)
df <- na.omit(dplyr::select(df, -c("id", "pub_date")))
fit <- kk_nowcast(df, e = 1, model = "KK", method = "MLE")
head(residuals(fit))
#> # A tibble: 6 × 2
#> time residual
#> <date> <dbl>
#> 1 1980-07-01 -0.000000883
#> 2 1980-10-01 -0.00000391
#> 3 1981-01-01 -0.00000223
#> 4 1981-04-01 0.00000123
#> 5 1981-07-01 -0.00000161
#> 6 1981-10-01 0.00000315
