| correct_by {geex} | R Documentation | 
Correct sandwich components
Description
Modifies the matrices in a sandwich_components object
using the function and options in a correct_control object.
The function correction is a utility for creating
correct_control objects.
Usage
correct_by(.components, .correct_control)
Arguments
.components | 
 an object of class   | 
.correct_control | 
 an object of class   | 
Details
See the finite sample corrections vignette for further examples.
Value
the result of .FUN in .correct_control.
See Also
fay_bias_correction and fay_df_correction
for corrections provided by geex
Examples
myee <- function(data){
   function(theta){
    c(data$Y1 - theta[1],
     (data$Y1 - theta[1])^2 - theta[2])
   }
 }
mybasis <- create_basis(
   estFUN = myee,
   data   = geexex)
mats <- estimate_sandwich_matrices(mybasis, .theta = c(5.04, 10.04))
correct_by(mats,
   .correct_control =  correction(fay_bias_correction, b = .75))
[Package geex version 1.1.1 Index]