Nothing
#' Linked stayer variance for change in means
#'
#' @keywords internal
variance_linked <- function(N0, N1, nS,
V0_ind, V1_ind,
C01_ind) {
if (nS <= 1L || is.na(C01_ind)) {
stop("Linked method requires at least two stayers with linked outcomes.")
}
V0_bar <- V0_ind / N0
V1_bar <- V1_ind / N1
C01_bar <- nS * C01_ind / (N0 * N1)
var_Delta <- V0_bar + V1_bar - 2 * C01_bar
if (var_Delta < 0) {
warning("Computed variance under the linked method is negative; setting to NA.")
var_Delta <- NA_real_
}
list(
V0_bar = V0_bar,
V1_bar = V1_bar,
C01_ind = C01_ind,
C01_bar = C01_bar,
var_Delta = var_Delta
)
}
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.