nnBraid: Braid()

Description Usage Arguments

Description

This function produces a "braid" visualization of a novel. The novel is divided into chunks of length = segment.length. Edges trace characters between chunks. Specific characters may be highlighted by specifying with the "characters" argument.

Usage

1
2
3
nnBraid(filename, segment.length = 1000, include.all = TRUE,
  local = FALSE, characters = NA, legend.position = "bottomright",
  bg.col = "white", edge.col = "gray80", char.only = FALSE)

Arguments

filename

Character string of text name, with associated Char.csv and .txt files.

segment.length

Numeric (Default = 1000). Sets length of each segment in # of words.

include.all

Logical vector or numerical range. If TRUE (default), processes whole text. If range (i.e. 1:18), processes only those chapters. If FALSE, will offer a prompt to determine a range.

local

Logical. If FALSE (default), looks in Google Drive for files. If TRUE, looks for filename in a folder with path data/filename/.

characters

Character vector. NA, or 1 or more uniqnames of characters in assocated Char.csv file. Specified characters are highlighted in plot.

legend.position

Character location (i.e. "bottomleft" default). Sets location of legend for spotlighted characters.

bg.col

Color (default = "white"). Sets background color.

edge.col

Color (default = "gray80"). Sets edge color.

char.only

Logical (default = FALSE). If TRUE, only highlighted characters (specified in "character" argument) are plotted.

set.voice

NA, or character string. If NA, Char.csv pulls voice from associated *Char.csv file. If "third", will ignore first-person pronouns. If "first", will attempt to transform all non-dialogue "I" and "me" into narrator, signaled on Char.csv file as "TextEgo".


seanrsilver/novnet documentation built on June 19, 2019, 12:44 a.m.