ena.set.creator: Wrapper to generate an ENA model

View source: R/ena.set.creator.R

ena.set.creatorR Documentation

Wrapper to generate an ENA model

Description

Generates an ENA model by constructing a dimensional reduction of adjacency (co-occurrence) vectors as defined by the supplied conversations, units, and codes.

Usage

ena.set.creator(
  data,
  codes,
  units,
  conversation,
  metadata = NULL,
  model = c("EndPoint", "AccumulatedTrajectory", "SeparateTrajectory"),
  weight.by = "binary",
  window = c("MovingStanzaWindow", "Conversation"),
  window.size.back = 1,
  include.meta = TRUE,
  groupVar = NULL,
  groups = NULL,
  runTest = FALSE,
  ...
)

Arguments

data

data.frame with containing metadata and coded columns

codes

vector, numeric or character, of columns with codes

units

vector, numeric or character, of columns representing units

conversation

vector, numeric or character, of columns to segment conversations by

metadata

vector, numeric or character, of columns with additional meta information for units

model

character: EndPoint (default), AccumulatedTrajectory, SeparateTrajectory

weight.by

"binary" is default, can supply a function to call (e.g. sum)

window

MovingStanzaWindow (default) or Conversation

window.size.back

Number of lines in the stanza window (default: 1)

include.meta

[TBD]

groupVar

vector, character, of column name containing group identifiers. If column contains at least two unique values, will generate model using a means rotation (a dimensional reduction maximizing the variance between the means of the two groups)

groups

vector, character, of values of groupVar column used for means rotation or statistical tests

runTest

logical, TRUE will run a Student's t-Test and a Wilcoxon test for groups defined by the groups argument

...

Additional parameters passed to model generation

Details

This function generates an ena.set object given a data.frame, units, conversations, and codes. After accumulating the adjacency (co-occurrence) vectors, computes a dimensional reduction (projection), and calculates node positions in the projected ENA space. Returns location of the units in the projected space, as well as locations for node positions, and normalized adjacency (co-occurrence) vectors to construct network graphs. Includes options for returning statistical tests between groups of units.

Value

ena.set object


rENA documentation built on May 29, 2024, 2:37 a.m.