blk.sequentialID: Create a Sequential ID

Description Usage Arguments Details Value Author(s) See Also Examples

View source: R/PCSmisc.R

Description

A new ID that numbers individuals sequentially starting at 1 is generated from an existing ID.

Usage

1

Arguments

id

A valid block-format ID.

Details

An ID is a factor that designates blocks in a block-format data set. This function takes an existing ID and generates a new one that preserves the same structure but is numeric and sequential starting at 1. Thus, this is a means of transforming an ID that is desciptive and alphanumeric into one that can be used with NONMEM.

Value

A valid block-format ID.

Author(s)

Ben Rich <[email protected]>

See Also

block-format

Examples

1
2
3
4
5
6
7
8
require(nlme)
data(Phenobarb)
dat <- Phenobarb[1:56,]  # First 4 subjects
attach(dat)

cbind(dat, newID=blk.sequentialID(asID(Subject)))

detach(dat)

benjaminrich/PCSmisc documentation built on Dec. 17, 2017, 12:50 a.m.