saemodel: Set up a SAE model

Description Usage Arguments Details Value Author(s) References See Also

Description

saemodel is the workhorse function to set up a model (i.e., an instance of the "saemodel" class). It is the starting point of every model fitting exercise. Once a model has been initilized/ set up, we consider estimating its parameter.

Usage

1
2
3
4
5
6
7
8
saemodel(formula, area, data, type = "b", na.omit = FALSE)

## S3 method for class 'saemodel'
print(x, ...)
## S3 method for class 'saemodel'
summary(object, ...)
## S3 method for class 'saemodel'
as.matrix(x, ...)

Arguments

formula

a two-sided linear formula object describing the fixed-effects part, with the response on the RHS of the ~ operator and the terms or regressors, separated by + operators, on the LHS of the formula.

area

a one-sided formula object. A ~ operator followed by only one single term defining the area-specific random-effect part

data

data.frame

type

either "a" or "b" refering to J.N.K. Rao's definition of model type A (area-level model) or B (unit-level model); default is type="b"

na.omit

a logical indicating whether NA should be removed (default is FALSE). Note that none of the algorithms can cope with missing values.

x

an object of the class "saemodel" (this argument is implicitly used by the print and as.matrix methods)

object

an object of the class "saemodel" (this argument is implicitly used by the summary method)

...

not used

Details

The step of setting up a SAE model is the starting point of any (robust) SAE modeling exercise. (Use the makedata to generate a synthetic dataset; see also, below). Here, we have to define the fixed-effects- and random-effects part of the model, and to tell R what data it shall use.

Once a model has been initilized/ set up, we consider estimating its parameter; see fitsaemodel.

Value

Instance of the S3 class "saemodel".

Author(s)

Tobias Schoch

References

Rao, J.N.K. (2003): Small Area Estimation, New York: John Wiley and Sons.

See Also

makedata


rsae documentation built on May 2, 2019, 5:50 p.m.