gencalibRaking {StratifiedSampling} | R Documentation |
Generalized calibration using raking ratio
Description
This function is inspired by the function calib
of the package sampling. It computes the g-weights of the calibration estimator.
Usage
gencalibRaking(Xs, Zs, d, total, q, max_iter = 500L, tol = 1e-09)
Arguments
Xs |
A matrix of calibration variables. |
Zs |
A matrix of instrumental variables with same dimension as Xs. |
d |
A vector, the initial weights. |
total |
A vector that represents the initial weights. |
q |
A vector of positive value that account for heteroscedasticity. |
max_iter |
An integer, the maximum number of iterations. Default = 500. |
tol |
A scalar that represents the tolerance value for the algorithm. Default = 1e-9. |
Details
More details on the different calibration methods can be read in Tillé Y. (2020).
Value
A vector, the value of the g-weights.
References
Tillé, Y. (2020). Sampling and estimation from finite populations. Wiley, New York
[Package StratifiedSampling version 0.4.2 Index]