obfuscatePed: obfuscatePed takes a pedigree object and creates aliases for...

Description Usage Arguments Value Examples

View source: R/obfuscatePed.R

Description

User provides a pedigree object (ped), the number of characters to be used for alias IDs (size), and the maximum number of days that the birthdate can be shifted (maxDelta).

Usage

1
2
3
4
5
6
7
obfuscatePed(
  ped,
  size = 6,
  maxDelta = 30,
  existingIds = character(0),
  map = FALSE
)

Arguments

ped

pedigree object

size

integer value indicating number of characters in alias IDs

maxDelta

integer value indicating maximum number of days that the birthdate can be shifted

existingIds

character vector of existing aliases to avoid duplication.

map

logical if TRUE a list object is returned with the new pedigree and a named character vector with the names being the original IDs and the values being the new alias values. Defaults to FALSE.

Value

An obfuscated pedigree

Examples

1
2
3
4
5
library(nprcgenekeepr)
ped <- qcStudbook(nprcgenekeepr::pedGood)
obfuscatedPed <- obfuscatePed(ped)
ped
obfuscatedPed

rmsharp/nprcmanager documentation built on April 24, 2021, 3:13 p.m.