Learn R Programming

translateSPSS2R (version 1.0.0)

xpssCasenum: Sequential numbering of cases

Description

R implementation of the SPSS $CASENUM system variable. xpssCasenum counts the number of cases within a variable, or respectively the number of observations in the dataset.

Usage

xpssCasenum(x)

Arguments

x
a (non-empty) data.frame or input data of class "xpssFrame".

Value

Returns a sequential atomic numeric or numeric vector.

Details

xpssCasenum fit well as ID-Variable.

See Also

Related Functions xpssCount , xpssDate , xpssDate11

Examples

Run this code
data(fromXPSS)

fromXPSS$id <- xpssCasenum(fromXPSS)

Run the code above in your browser using DataLab