xpssCount: Counts frequencies of specific observations

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

Description

R implementation of the SPSS $COUNT system variable.

Usage

1
xpssCount(x, variables, count)

Arguments

x

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

variables

atomic character or character vector with the name of the variables.

count

atomic character or atomic numeric pattern.

Details

Count displays the frequencies of observations matching the count statement.

Value

A vector of the same length as x.

Author(s)

Bastian Wiessner

See Also

Related Functions xpssAny %in% is.element

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
data(fromXPSS)

xpssCount(x=fromXPSS,
   variables = "V1", count=list(exact="Nissan"))

xpssCount(x=fromXPSS,
   variables = "V5", count=list(exact=2))

xpssCount(fromXPSS,
   variables = span(fromXPSS, from = "V5",
                             to = "V7_2"),
                   count = list(from = "lo",
                                  to = 100))


Search within the translateSPSS2R package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.