getDiditXWave: Returns dataframe with flags indicating survey completion

Description Usage Arguments Value Examples

Description

Returns dataframe with flags indicating survey completion

Usage

1
getDiditXWave(pWavVec, pSchVec)

Arguments

pWavVec

An ordered numeric vector of wave SIDs to be included in the analysis. Waves 2, 6, and 10 are summer waves; no Short Survey or Long Survey data were collected. Hence these waves should not ever be specified.

pSchVec

A numeric vectorof School IDs to be included in the analysis.

pElig

The minimum number of eligible waves for SID to be included.

pDid

The minimum number of survey-completed waves for SID to be included.

Value

A (#eligible SIDs x length(pWavVec)+1) dataframe. Col 1 is SID, Cols 2 on (each named 'wK', where K is the kth ordered wave in pWavVec) are flags with the integer 1 if individual SID 'completed' a survey for that wave (completion is determined in the function 'allNQQNotNA')

Examples

1
2
3
4
# gets dataframe including SIDs for waves 1, 3, 4, and 5, schools 3-6 and
# 30 (one school district); each included SID was eligible for the Short
# survey at least once, and completed at least 1 survey in these waves.
sidVec <- getSIDSet(c(1, 3, 4, 5), c(3, 4, 5, 6, 30), 1, 1)

johninpdx/RSTools documentation built on May 19, 2019, 5:15 p.m.