| BLE_SSRS {BayesSampling} | R Documentation | 
Stratified Simple Random Sample BLE
Description
Creates the Bayes Linear Estimator for the Stratified Simple Random Sampling design (without replacement)
Usage
BLE_SSRS(ys, h, N, m = NULL, v = NULL, sigma = NULL)
Arguments
ys | 
 vector of sample observations or sample mean for each strata (  | 
h | 
 vector with number of observations in each strata.  | 
N | 
 vector with the total size of each strata.  | 
m | 
 vector with the prior mean of each strata. If   | 
v | 
 vector with the prior variance of an element from each strata (bigger than   | 
sigma | 
 vector with the prior estimate of variability (standard deviation) within each strata of the population. If   | 
Value
A list containing the following components:
-  
est.beta- BLE of Beta (BLE for the individuals in each strata) -  
Vest.beta- Variance associated with the above -  
est.mean- BLE for each individual not in the sample -  
Vest.mean- Covariance matrix associated with the above -  
est.tot- BLE for the total -  
Vest.tot- Variance associated with the above 
Source
https://www150.statcan.gc.ca/n1/en/catalogue/12-001-X201400111886
References
Gonçalves, K.C.M, Moura, F.A.S and Migon, H.S.(2014). Bayes Linear Estimation for Finite Population with emphasis on categorical data. Survey Methodology, 40, 15-28.
Examples
ys <- c(2,-1,1.5, 6,10, 8,8)
h <- c(3,2,2)
N <- c(5,5,3)
m <- c(0,9,8)
v <- c(3,8,1)
sigma <- c(1,2,0.5)
Estimator <- BLE_SSRS(ys, h, N, m, v, sigma)
Estimator
# Same example but informing sample means instead of sample observations
y1 <- mean(c(2,-1,1.5))
y2 <- mean(c(6,10))
y3 <- mean(c(8,8))
ys <- c(y1, y2, y3)
h <- c(3,2,2)
N <- c(5,5,3)
m <- c(0,9,8)
v <- c(3,8,1)
sigma <- c(1,2,0.5)
Estimator <- BLE_SSRS(ys, h, N, m, v, sigma)
Estimator