Freq {bruceR} | R Documentation |
Frequency statistics.
Description
Frequency statistics.
Usage
Freq(x, varname, labels, sort = "", digits = 1, file = NULL)
Arguments
x |
A vector of values (or a data frame). |
varname |
[Optional] Variable name, if |
labels |
[Optional] A vector re-defining the labels of values. |
sort |
|
digits |
Number of decimal places of output. Defaults to |
file |
File name of MS Word ( |
Value
A data frame of frequency statistics.
Examples
data = psych::bfi
## Input `data$variable`
Freq(data$education)
Freq(data$gender, labels=c("Male", "Female"))
Freq(data$age)
## Input one data frame and one variable name
Freq(data, "education")
Freq(data, "gender", labels=c("Male", "Female"))
Freq(data, "age")
[Package bruceR version 2024.6 Index]