Learn R Programming

EnQuireR (version 0.10)

ENbarplot: Plots of categorical variables

Description

This function allows to obtain barplots either sorted by frequency or by alphabetical order. The percentage of missing values is indicated at the top of the graphical device.

Usage

ENbarplot(dataset,X,spl=FALSE,numr=NULL,numc=NULL,report=FALSE)

Arguments

dataset
a data frame
X
the numbers of the variables to be plotted
spl
if TRUE, the barplots will be sorted per length
numr
the number of plots per row (by default 2)
numc
the number of plots per column (by default 2)
report
a logical value. If TRUE, a report is automatically generated

Details

The colour changes depending on the number of individuals of the category. If report=TRUE, a directory named "EnQuireR" is created in your working directory (which can be known thanks to the getwd() function). This directory contains the final pdf report and also the teX file used to produce it.

See Also

XvsYbarplot which gives barplots of a categorical variable depending on the categoricals of another categorical variable.

Examples

Run this code
## Not run: 
# data(tea)
# ENbarplot(tea,c(18,20,21,23))
# 
# ENbarplot(tea,c(18,20,21,23),report=TRUE)
# ## End(Not run)

Run the code above in your browser using DataLab