systematic: Systematic Random Sampling

View source: R/systematic.R

systematicR Documentation

Systematic Random Sampling

Description

Determines the elements to be included for the desired sample; the first element is determined randomly with succeeding elements determined through the addition of the kth element.

Usage

systematic(x, y)

Arguments

x

Population for the study

y

Required sample for the study

Details

Used to systematically select the elements that will be included in the sample using the kth element; the first element is randomly selected.

Value

Returns a vector which reflects the systematically randomized numbers with the last number not going beyond the last element of the Population; number of elements of said vector is equal to the required sample size

Author(s)

Paolo G. Hilado

Examples

systematic(500, 10)
 [1]  20  70 120 170 220 270 320 370 420 470

## The function is currently defined as
function (x, y)
{
    k <- x/y
    a <- runif(1, 1, k)
    b <- round(a, digits = 0)
    c <- seq(b, b + k * (y - 1), k)
    round(c, digits = 0)
  }

Dcroix/RSamplingz documentation built on April 30, 2022, 8:33 a.m.