ratid_to_usern: Convert a RATSS study ID to username format

Description Usage Arguments See Also Examples

View source: R/ratid_to_usern.R

Description

Converts a RATSS code/study ID (in the format e.g. "11 0104 01 01 14" or without any spaces "110104010114") to a <family>_<twin_no> format (e.g. "104_1"). For parents, this leads to them having usernames in the format "<family no>_5" or "<family no>_6". Note that this parent coding might not be what you want or what has been used previously.

Usage

1

Arguments

ratid

a string/character vector with a single RATSS code

See Also

gsub substr

Examples

1
2
3
4
x <- "11 0104 01 01 14"
ratid_to_usern(x)
y <- "110104010114"
ratid_to_usern(y)

AnonZebra/synratss documentation built on Oct. 9, 2021, 2:31 a.m.