SurrogateGuidedSample: SurrogateGuidedSample

Description Usage Arguments Value

View source: R/SurrogateGuidedSample.R

Description

Makes a sample enriched for cases using ideas from surrogate guided sampling strategy

Usage

1
2
SurrogateGuidedSample(df, n_sample = 100, stratify_var = NULL, nz1 = NULL,
  nz0 = NULL, REPLACE = FALSE, IS_SRS = FALSE)

Arguments

df

Input data frame

n_sample

Sample size

stratify_var

quo(column in df) to stratify sample on; defaults to NULL for simple random sample

nz1

Number of surrogate positives in sample

nz0

Number of surrogate negatives in sample

REPLACE:

whether to sample with replacement

Value

sampled.df: A data frame with length n_sample according to specified sampling scheme


wlktan/surrogateSampling documentation built on May 23, 2019, 3:07 p.m.