Dataset for saery package

Description

A simulated dataset created by the authors in order to check the correct operation of the saery package

Usage

1

Format

A simulated data frame with 2000 observations on the following 6 variables.

Area

a numeric vector with the area (domain) of the data

Period

a numeric vector with the period (subdomain) of the data

ydi

a numeric vector with the direct estimator of the indicator of interest for area (domain)

ones

a numeric vector. This is only needed to include the intercept parameter in the model

xdi

a numeric vector containing the aggregated (population) values of an auxiliary variable

sigma2edi

a numeric vector with the known variance of the error term

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
sigma2edi <- datos[,6]
X <- as.matrix(datos[,5])
ydi <- datos[,3]
D <- length(unique(datos[,1]))
md <- rep(length(unique(datos[,2])), D)

output.fit.ar1 <- fit.saery(X, ydi, D, md, sigma2edi, "AR", 0.9)
output.fit.ar1

#For computational reasons B is too low. We recomend to increase up to 100
eblup.output.ar1 <- eblup.saery(X, ydi, D, md, sigma2edi, "a", plot = TRUE, B = 2)
eblup.output.ar1