Description Usage Arguments Details Value References
View source: R/obpFHbenchmark.R
This function computes the benchmarked Observed Best Predictor (OBP) for Fay-Herriot model. Depending on the method
specified by the user it computes the Adjusted OBP or Augmented OBP or both.
1 2 | obpFHbenchmark(formula, data, errorvar, weight, method = c("adjusted",
"augmented"), randvar = NULL, maxiter = 100, precision = 1e-04)
|
formula |
an object of class formula (or one that can be coerced to that class): a symbolic description of the model to be fitted. The variables included in formula must have a length equal to the number of small areas. More about the model specification are given under Details. |
data |
optional data frame containing the variable names in |
errorvar |
vector containing the variances of the random errors for all small areas. |
weight |
vector containing the sampling weights of small areas. If sum of the weights is not 1, the weights are normalized. |
method |
string specifying the benchmarking method. Options are "adjusted" and "augmented". Computes both if not specified. See Details for more usage information. |
randvar |
variance of the random effect. If not supplied, BPE is estimated. |
maxiter |
maximum number of iterations used in estimating randvar. |
precision |
covergence tolerance limit for estimating randvar. |
If method
is set to "adjusted", only obpAdjusted
is returned.
If method
is set to "augmented", obpAugmented, A.BPE.aug
and beta.BPE.aug
are returned.
The variance of the random effect can be specified by the user. Otherwise the function will calculate its Best Predictive Estimator (BPE). In the process of of computing OBP it also calculates the BPE of the regression coefficients of the fixed effect.
formula
is specified in the form response ~ predictors
where the predictors are separated by +
. formula
has an implied intercept term. To remove the intercept term, use either y ~ x - 1
or y ~ 0 + x
.
The function will return a list with all the following objects by default.
obpAdjusted |
a vector of adjusted OBP values. |
obpAugmented |
a vector of augmented OBP values. |
A.BPE.aug |
BPE of variance component of random effects under the augmented model (if not provided by the user). |
beta.BPE.aug |
BPE of fixed effects regression coefficients under the augmented model. |
Bandyopadhyay R, Jiang J (2017) "Benchmarking the Observed Best Predictor"
Jiang J, Nguyen T, and Rao J. S. (2011), "Best Predictive Small Area Estimation", Journal of the American Statistical Association.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.