jkr_iccs: jkr_iccs() computes jackknifes for ICCS 2009 and ICCS 2016

View source: R/jkr_iccs.R

jkr_iccsR Documentation

jkr_iccs() computes jackknifes for ICCS 2009 and ICCS 2016

Description

jkr_iccs() computes jackknifes for ICCS 2009 and ICCS 2016

Usage

jkr_iccs(data, nrep, jkz, jki, wgt)

Arguments

data

data frame object which contains the rest of the arguments

nrep

number of replicates

jkz

vector containing the pseudo strata (75 in ICCS studies)

jki

vector selecting which school goes into the replicate

wgt

total survey weights

Details

a loop function to create jackknifes replicate weights (author: 'merivera@uc.cl')

Value

the original data frame with the jacknnifes replicates added.

Examples

library(dplyr)
data_frame_with_jackknifes <- data_frame %>%
                              r4sda::jackknifes_iccs(
                              data = .,
                              nrep = 75,
                              jkz = 'JKZONEZ',
                              jki = 'JKREPS',
                              wgt = 'TOTWGTS')


dacarras/r4sda documentation built on Nov. 9, 2023, 10:17 a.m.