plot.formality: Plots a formality Object

Description Usage Arguments Value

View source: R/formality.R

Description

Plots a formality object including the parts of speech used to calculate contextual/formal speech.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
## S3 method for class 'formality'
plot(
  x,
  point.pch = 20,
  point.cex = 0.5,
  point.colors = c("gray65", "red"),
  bar.colors = NULL,
  short.names = TRUE,
  min.wrdcnt = NULL,
  order.by.formality = TRUE,
  plot = TRUE,
  ...
)

Arguments

x

The formality object.

point.pch

The plotting symbol.

point.cex

The plotting symbol size.

point.colors

A vector of colors (length of two) to plot word count and formality score.

bar.colors

A palette of colors to supply to the bars in the visualization. If two palettes are provided to the two bar plots respectively.

short.names

logical. If TRUE shortens the length of legend and label names for more compact plot width.

min.wrdcnt

A minimum word count threshold that must be achieved to be considered in the results. Default includes all subgroups.

order.by.formality

logical. If TRUE the group formality plot will be ordered by average formality score, otherwise alphabetical order is assumed.

plot

logical. If TRUE the plot will automatically plot. The user may wish to set to FALSE for use in knitr, sweave, etc. to add additional plot layers.

...

ignored

Value

Invisibly returns the ggplot2 objects that form the larger plot.


trinker/qdap documentation built on Sept. 30, 2020, 6:28 p.m.