bio_frequency: Function to generate a frequency table

View source: R/bio_frequency.R

bio_frequencyR Documentation

Function to generate a frequency table

Description

This function generates a frequency table from factor or character vector columns in a data frame

Usage

bio_frequency(
  data,
  columns,
  freq.percent = "both",
  include.na = TRUE,
  remove.vars = NULL
)

Arguments

data

A data frame containing columns to be counted

columns

Column names or indices to be counted in data

freq.percent

Whether the table should include frequency counts, percentages or both (options = c("freq", "percent", "both")). Default="both"

include.na

Include NA values (options are TRUE/FALSE, default=TRUE)

remove.vars

Character vector of variables not to be included in the counts (e.g. remove.vars = c("") remove blanks from the count)

Examples

bio_frequency(mtcars, columns=c("vs", "am"))

KatrionaGoldmann/BioOutputs documentation built on May 21, 2022, 1:24 p.m.