eblupMFH3 {msae}R Documentation

EBLUPs based on a Heteroscedastic Autoregressive Multivariate Fay Herriot (Model 3)

Description

This function gives the EBLUP and MSE based on a heteroscedastic autoregressive multivariate Fay-Herriot model (model 3).

Usage

eblupMFH3(formula, vardir, MAXITER = 100, PRECISION = 1e-04, data)

Arguments

formula

an object of class list of formula, describe the model to be fitted

vardir

if data is available, it is vector containing name of sampling variances of direct estimators. if not, it is data frame of sampling variances of direct estimators. The order is : var1, var2, . , var(k) , cov12, . cov1k, cov23, . , cov(k-1)(k)

MAXITER

maximum number of iterations allowed in the Fisher-scoring algorithm, Default: 100

PRECISION

convergence tolerance limit for the Fisher-scoring algorithm, Default: 1e-4

data

dataframe containing the variables named in formula and vardir

Value

The function returns a list with the following objects:

eblup

a dataframe with the values of the EBLUP estimators

MSE

a dataframe with the estimated mean squared errors of the EBLUPs for the small domains

randomEffect

a dataframe with the values of the random effect estimators

Rmatrix

a block diagonal matrix composed of sampling errors

fit

a list containing the following objects:

Examples

## Load dataset
data(datasae3)

# Compute EBLUP and MSE of Y1 Y2 and Y3  based on Model 3
# using auxiliary variables X1 and X2 for each dependent variable

## Using parameter 'data'
Fo <- list(f1=Y1~X1+X2,
           f2=Y2~X1+X2,
           f3=Y3~X1+X2)
vardir <- c("v1", "v2", "v3", "v12", "v13", "v23")
m3 <- eblupMFH3(Fo, vardir, data=datasae3)

## Without parameter 'data'
Fo <- list(f1=datasae3$Y1~datasae3$X1+datasae3$X2,
           f2=datasae3$Y2~datasae3$X1+datasae3$X2,
           f3=datasae3$Y3~datasae3$X1+datasae3$X2)
vardir <- datasae3[,c("v1", "v2", "v3", "v12", "v13", "v23")]
m3 <- eblupMFH3(Fo, vardir)

m3$eblup   # see the EBLUP estimators
m3$MSE   # see MSE of EBLUP estimators


[Package msae version 0.1.5 Index]