plotLetter: plotLetter

Description Usage Arguments Value Examples

View source: R/PlotFunctions.R

Description

This function returns a plot of a single letter extracted from a document. It uses the letterList parameter from the processHandwriting function and accepts a single value as whichLetter. Dims requires the dimensions of the entire document, since this isn't contained in processHandwriting.

Usage

1
2
3
4
5
6
7
8
plotLetter(
  letterList,
  whichLetter,
  dims,
  showPaths = TRUE,
  showCentroid = TRUE,
  showSlope = TRUE
)

Arguments

letterList

Letter list from processHandwriting function

whichLetter

Single value in 1:length(letterList) denoting which letter to plot.

dims

Dimensions of the original document

showPaths

Whether the calculated paths on the letter should be shown with numbers.

showCentroid

Whether the centroid should be shown

showSlope

whether the slope should be shown

Value

Plot of single letter.

Examples

1
2
3
4
5
6
7
8
twoSent_document = list()
twoSent_document$image = twoSent
twoSent_document$thin = thinImage(twoSent_document$image)
twoSent_processList = processHandwriting(twoSent_document$thin, dim(twoSent_document$image))

dims = dim(twoSent_document$image)
plotLetter(twoSent_processList$letterList, 1, dims)
plotLetter(twoSent_processList$letterList, 4, dims)

handwriter documentation built on Aug. 16, 2021, 5:07 p.m.