Learn R Programming

translateSPSS2R (version 1.0.0)

xpssNofCases: Selects the first n rows of the dataset

Description

R implementation of the SPSS N OF CASES argument.

Usage

xpssNofCases(x, n = NULL)

Arguments

x
input data.
n
atomic numeric with the value of n.

Value

Output is the narrowed dataset.

Details

xpssNofCases can be used to select via command the first N cases in the data file. xpssNofCases permanently modifies the data set. NOTE: For temporary case selection, specify xpssTemporary before xpssNofCases.

See Also

Related Functions drop subset

Examples

Run this code
data(fromXPSS)
xpssNofCases(fromXPSS, n = 10)

Run the code above in your browser using DataLab