Learn R Programming

uwo4419 (version 0.3.0)

histDiscrete: Create a histogram from a discrete variable

Description

A histogram for a discrete variable is basically a bar chart with no space between the bars.

Usage

histDiscrete(x, data, ...)

Arguments

x

A character string giving the name of the variable to be plotted.

data

A data frame in which x can be found.

...

Not implemented

Value

A ggplot.

Examples

Run this code
# NOT RUN {
data(alberta)
alberta$k3c <- ifelse(alberta$k3c > 11, NA, alberta$k3c)
histDiscrete("k3c", alberta)
# }

Run the code above in your browser using DataLab